mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 15:57:21 +01:00
fix: prevent the global hooks from piling up (#351)
this happens due to the global `*All()` hooks (before & after) being defined as static. We should be a good citizen and we need to clean up our mess for the next person in the test instance constructor
This commit is contained in:
@ -73,6 +73,7 @@ trait Testable
|
|||||||
{
|
{
|
||||||
$this->__test = $test;
|
$this->__test = $test;
|
||||||
$this->__description = $description;
|
$this->__description = $description;
|
||||||
|
self::$beforeAll = self::$afterAll = null;
|
||||||
|
|
||||||
parent::__construct('__test', $data);
|
parent::__construct('__test', $data);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user