File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -23,6 +23,10 @@ protected function setUp(): void
2323 'SPC_TARGET ' => getenv ('SPC_TARGET ' ),
2424 'SPC_LIBC ' => getenv ('SPC_LIBC ' ),
2525 ];
26+ // Temporarily set private GlobalEnvManager::$initialized to false (use reflection)
27+ $ reflection = new \ReflectionClass (GlobalEnvManager::class);
28+ $ property = $ reflection ->getProperty ('initialized ' );
29+ $ property ->setValue (null , false );
2630 }
2731
2832 protected function tearDown (): void
@@ -35,6 +39,10 @@ protected function tearDown(): void
3539 putenv ("{$ key }= {$ value }" );
3640 }
3741 }
42+ // Temporarily set private GlobalEnvManager::$initialized to false (use reflection)
43+ $ reflection = new \ReflectionClass (GlobalEnvManager::class);
44+ $ property = $ reflection ->getProperty ('initialized ' );
45+ $ property ->setValue (null , true );
3846 }
3947
4048 public function testGetInitializedEnv (): void
Original file line number Diff line number Diff line change @@ -34,17 +34,6 @@ protected function tearDown(): void
3434 }
3535 }
3636
37- /**
38- * @dataProvider libcProvider
39- */
40- public function testIsStatic (string $ libc , bool $ expected ): void
41- {
42- putenv ("SPC_LIBC= {$ libc }" );
43-
44- $ result = SPCTarget::isStatic ();
45- $ this ->assertEquals ($ expected , $ result );
46- }
47-
4837 /**
4938 * @dataProvider libcProvider
5039 */
You can’t perform that action at this time.
0 commit comments