Skip to content

Commit 6493ed1

Browse files
committed
Added sections support
1 parent 5484677 commit 6493ed1

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/Module/Nette.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,12 @@ public function _before(TestCase $test)
6464
};
6565

6666
if ($test instanceof ConfigFilesInterface) {
67-
foreach ($test->getConfigFiles() as $file) {
68-
$this->configurator->addConfig($this->path . DIRECTORY_SEPARATOR . $this->suite . DIRECTORY_SEPARATOR . $file);
67+
foreach ($test->getConfigFiles() as $file => $section) {
68+
if (!is_string($file)) {
69+
$file = $section;
70+
$section = NULL;
71+
}
72+
$this->configurator->addConfig($this->path . DIRECTORY_SEPARATOR . $this->suite . DIRECTORY_SEPARATOR . $file, $section);
6973
}
7074
}
7175

0 commit comments

Comments
 (0)