More tests

This commit is contained in:
Nuno Maduro
2023-05-27 14:08:38 +01:00
parent a90b90ad29
commit 26a6e7d712
12 changed files with 101 additions and 15 deletions

View File

@ -7,7 +7,11 @@ beforeEach(function () use ($state) {
});
afterEach(function () {
$this->state->bar = 2;
$this->state->bar = 1;
});
afterEach(function () {
unset($this->state->bar);
});
it('does not get executed before the test', function () {
@ -18,3 +22,7 @@ it('gets executed after the test', function () {
expect($this->state)->toHaveProperty('bar');
expect($this->state->bar)->toBe(2);
});
afterEach(function () {
$this->state->bar = 2;
});