diff --git a/tests/system/Config/BaseConfigTest.php b/tests/system/Config/BaseConfigTest.php index 76861ccb12ad..958387cc6b6d 100644 --- a/tests/system/Config/BaseConfigTest.php +++ b/tests/system/Config/BaseConfigTest.php @@ -290,9 +290,9 @@ public function testRedoingDiscoveryWillStillSetDidDiscoveryPropertyToTrue(): vo $locator->method('search')->with('Config/Registrar.php')->willReturn([]); Services::injectMock('locator', $locator); + $this->setPrivateProperty(RegistrarConfig::class, 'didDiscovery', false); + $config = new RegistrarConfig(); - $this->setPrivateProperty($config, 'didDiscovery', false); - ($this->getPrivateMethodInvoker($config, 'registerProperties'))(); $this->assertTrue($this->getPrivateProperty($config, 'didDiscovery')); }