public function testHas_withNotExistingProperties_shouldReturnFalse() { $accepts = ['FOO']; $i = ConfigurationContainer::getInstance(); $i->attachable($accepts); $i->set('FOO', 'FOO'); $this->assertFalse(ConfigurationContainer::has('BAR')); }
public function testLoadEnv_withMissingRequiredEnv_shouldThrowExpectedException() { $expectedException = RuntimeException::class; $this->setExpectedException($expectedException); $envfile = sprintf('%s/files/%s', dirname(__FILE__), 'test_env_file'); $required = ['THIS_IS_REQUIRED_ENV']; $i = ConfigurationContainer::getInstance(); $i->loadEnv($envfile, ['expect' => $required]); }