Back

hey #laravel devs,
Did you know running php artisan test executes all your tests and then outputs the results? But there's a cooler way with PestPHP!

🛑 Use -- bail to stop test execution as soon as any test fails! This saves you time by not running the whole test suite when a bug pops up. Game changer, right?

See below, my actual test suite contains 37 tests, but using bail it stopped at 6th test case.

This saved a lot time by not executing further test cases, so i can focus on fixing failing test.

Embrace smarter testing and save precious debugging hours. Happy coding! 💻❤️

#laravel #php #pest #testing
image

1

143

  • No matching results...
  • Searching...

/ 1000

Thanks ! This will be helpful indeed , i am currently running a lot of tests for my project

1

178

I am glad that you found it helpfull

119