Blog

My Articles

Here I share my thoughts, ideas, and experiences.
I write about PHP & Laravel and other web development topics in general.

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...


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...


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...


Image upload test journey

For my open-source project, I needed an option for the user to upload an image. Furthermore, this image needed to be resized. For resizing, I used a well-know package called Intervention. The testing...

My Work Featured on Laravel News