We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When I add global hooks beforeAll or afterAll inside tests/Pest.php, they do not work, while beforeEach and afterEach are being called properly.
composer global require laravel/installer
laravel new example-app
choosing pest for testing.
in tests/Pest.php, I added:
// tests/Pest.php pest() ->beforeAll(function () { echo "Before All\n"; }) ->beforeEach(function () { echo "Before Each\n"; }) ->in('Unit');
running: php artisan test
php artisan test
I see BeforeEach in output, but I do not see BeforeAll.
No response
3.7.4
8.4.2
Windows
The text was updated successfully, but these errors were encountered:
@HassanDomeDenea I have pr with fix for it waiting for 2 months or so
#1322
these hooks don't work since 3.0.4
downgrade to 3.0.3 for time being
Sorry, something went wrong.
No branches or pull requests
What Happened
When I add global hooks beforeAll or afterAll inside tests/Pest.php, they do not work, while beforeEach and afterEach are being called properly.
How to Reproduce
composer global require laravel/installer
laravel new example-app
choosing pest for testing.
in tests/Pest.php, I added:
running:
php artisan test
I see BeforeEach in output, but I do not see BeforeAll.
Sample Repository
No response
Pest Version
3.7.4
PHP Version
8.4.2
Operation System
Windows
Notes
No response
The text was updated successfully, but these errors were encountered: