Add ability to define multiple hooks for the same directory in Pest.php

This commit is contained in:
Bastien Philippe
2023-09-15 15:54:26 +02:00
committed by Nuno Maduro
parent 9c077ed352
commit 9d58e1a77e
6 changed files with 160 additions and 19 deletions

View File

@ -4,16 +4,16 @@ uses()->afterEach(function () {
expect($this)
->toHaveProperty('ith')
->and($this->ith)
->toBe(0);
->toBe(1);
$this->ith = 1;
$this->ith = 2;
});
afterEach(function () {
expect($this)
->toHaveProperty('ith')
->and($this->ith)
->toBe(1);
->toBe(2);
});
test('global afterEach execution order', function () {