parent
d449f79a0d
commit
cb4ddbe4e7
3 changed files with 18 additions and 3 deletions
tests
|
@ -36,6 +36,20 @@ class ConfigPhpTest extends \PHPUnit_Framework_TestCase
|
|||
$this->assertEquals(array(), $this->configIO->read('nope'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Read an empty existent config file -> array with blank default values.
|
||||
*/
|
||||
public function testReadEmpty()
|
||||
{
|
||||
$dataFile = 'tests/utils/config/emptyConfigPhp.php';
|
||||
$conf = $this->configIO->read($dataFile);
|
||||
$this->assertEmpty($conf['login']);
|
||||
$this->assertEmpty($conf['title']);
|
||||
$this->assertEmpty($conf['titleLink']);
|
||||
$this->assertEmpty($conf['config']);
|
||||
$this->assertEmpty($conf['plugins']);
|
||||
}
|
||||
|
||||
/**
|
||||
* Write a new config file.
|
||||
*/
|
||||
|
|
1
tests/utils/config/emptyConfigPhp.php
Normal file
1
tests/utils/config/emptyConfigPhp.php
Normal file
|
@ -0,0 +1 @@
|
|||
<?php
|
Loading…
Add table
Add a link
Reference in a new issue