Skip to content

Running Tests

Azizul Hakim edited this page Oct 20, 2023 · 3 revisions

To ensure the reliability and correctness of your application, it's essential to execute tests. Follow these simple steps:

  1. Running Tests:

    You have two convenient options for running tests:

    • Using Pest:

      Execute tests with Pest, a delightful PHP testing framework. Simply run the following command:

      ./vendor/bin/pest

      If you are running with Sail, you can use this command:

      ./vendor/bin/sail test
      # or if you have an alias configured:
      sail test
    • Using Artisan:

      Laravel's Artisan command-line tool provides seamless testing capabilities. Run the tests with the following Artisan command:

      php artisan test

      If you are running Sail, you can use this command:

      ./vendor/bin/sail artisan test
      # or if you have an alias configured:
      sail artisan test

Running tests is crucial to ensure the reliability and correctness of your application's functionality. The above commands will initiate the testing process and provide you with valuable insights into the quality of your codebase.