We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
enum_exists
1 parent b30d276 commit 0987f26Copy full SHA for 0987f26
Tests/EnumExistsMockTest.php
@@ -23,6 +23,9 @@ class EnumExistsMockTest extends TestCase
23
{
24
public static function setUpBeforeClass(): void
25
26
+ // Require the fixture file to allow PHP to be fully aware of the enum existence
27
+ require __DIR__.'/Fixtures/ExistingEnumReal.php';
28
+
29
ClassExistsMock::register(__CLASS__);
30
}
31
@@ -34,6 +37,11 @@ protected function setUp(): void
34
37
]);
35
38
36
39
40
+ public static function tearDownAfterClass(): void
41
+ {
42
+ ClassExistsMock::withMockedEnums([]);
43
+ }
44
45
public function testClassExists()
46
47
$this->assertFalse(class_exists(ExistingEnum::class));
0 commit comments