Basic information
About pest-testing
Tests applications using the Pest 4 PHP framework. Activates when writing tests, creating unit or feature tests, adding assertions, testing Livewire components, browser testing, debugging test failures, working with datasets or mocking; or when the user mentions test, spec, TDD, expects, assertion, coverage, or needs to verify functionality works.
pest-testing is an agent skill listed in the AddMCP.net directory, published by spatie. Runtime: PHP. License: MIT. The repository has 647 GitHub stars. Source code is hosted on github.com. Related topics: application, blog, hacktoberfest, laravel, php.
Overview
What is pest-testing?
name: pest-testing description: >- Tests applications using the Pest 4 PHP framework. Activates when writing tests, creating unit or feature tests, adding assertions, testing Livewire components, browser testing, debugging test failures, working with datasets or mocking; or when the user mentions test, spec, TDD, expects, assertion, coverage, or needs to verify functionality works.
Pest Testing 4
When to Apply
Activate this skill when:
- Creating new tests (unit, feature, or browser)
- Modifying existing tests
- Debugging test failures
- Working with browser testing or smoke testing
- Writing architecture tests or visual regression tests
Documentation
Use search-docs for detailed Pest 4 patterns and documentation.
Basic Usage
Assertions
Mocking
Import mock function before use: use function Pest\Laravel\mock;
Datasets
Pest 4 Features
Common Pitfalls
- Not importing
use function Pest\Laravel\mock;before using mock - Using
assertStatus(200)instead ofassertSuccessful() - Forgetting datasets for repetitive validation tests
- Deleting tests without approval
- Forgetting
assertNoJavascriptErrors()in browser tests
Comments
No comments yet
Be the first to share feedback about this listing. Sign in to leave a comment.
Sign In