Blog


February 16, 2021

Contract Test

When testing 3rd party API call (dealing with external resources), one of the problems is that those tests are slow. One of the solutions is to use fake classes. On the outside, the fake class...

Read

February 11, 2021

Tips on testing PHP exceptions

Let's have a shamefully simple class like this: Back in the days, there were three options for how to test the exception. From PHPunit 9.0 onwards, only two remain. expectedException annotation...

Read

January 15, 2021

Laravel and Hotwire Intro

Basecamp released a new tool called Hotwire that helps build new modern SPA like web apps without much javascript. It is a backend framework agnostic. Hotwire is an alternative approach to...

Read

January 5, 2021

Laravel Mailable Testing Tips

According to Laravel News: Testing Mailable Content in Laravel 8 few additional methods for testing mailable were added to Laravel 8.18.0. Those are: And here is an example of how you can use...

Read