Skip to content

Commit

Permalink
Merge pull request #56 from stof/fix_state_reset
Browse files Browse the repository at this point in the history
Fix the state resetting between tests
  • Loading branch information
greg0ire authored Jun 3, 2023
2 parents 9340e28 + f6f2c45 commit 612a3ee
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/Doctrine/Deprecations/DeprecationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class DeprecationTest extends TestCase

public function setUp(): void
{
// reset the global state of Deprecation class accross tests
// reset the global state of Deprecation class across tests
$reflectionProperty = new ReflectionProperty(Deprecation::class, 'ignoredPackages');
$reflectionProperty->setAccessible(true);
$reflectionProperty->setValue([]);
Expand All @@ -34,6 +34,8 @@ public function setUp(): void
$reflectionProperty->setAccessible(true);
$reflectionProperty->setValue([]);

Deprecation::disable();

Deprecation::enableTrackingDeprecations();
}

Expand Down

0 comments on commit 612a3ee

Please sign in to comment.