diff --git a/tests/AbstractConfigTest.php b/tests/AbstractConfigTest.php index 2a280de..7fcd700 100644 --- a/tests/AbstractConfigTest.php +++ b/tests/AbstractConfigTest.php @@ -502,4 +502,16 @@ public function testRemove() $this->config->remove('application'); $this->assertNull($this->config['application']); } + + public function testDefaultOptionsSetOnInstantiationDoNotOverwriteSections() + { + $config = new SimpleConfig( + [ + 'application' => ['secret' => 'verysecret'] + ] + ); + $this->assertEquals('configuration', $config->get('application.name')); + $this->assertEquals('verysecret', $config->get('application.secret')); + } } +