IniWriterTest: make recently added tests more expressive

refs #11743
This commit is contained in:
Alexander A. Klimov 2016-10-17 13:51:58 +02:00
parent 58b2e6c00f
commit 99866bfdbe
1 changed files with 9 additions and 9 deletions

View File

@ -409,9 +409,9 @@ EOD;
$config->setSection('garbage', $section);
$iniWriter = new IniWriter($config, '/dev/null');
$this->assertEquals(
0,
preg_match('/foobar/', $iniWriter->render()),
$this->assertNotContains(
'foobar',
$iniWriter->render(),
'IniWriter persists section keys with null values'
);
}
@ -424,9 +424,9 @@ EOD;
$config->setSection('garbage', $section);
$iniWriter = new IniWriter($config, '/dev/null');
$this->assertEquals(
1,
preg_match('/foobar/', $iniWriter->render()),
$this->assertContains(
'foobar',
$iniWriter->render(),
'IniWriter doesn\'t persist section keys with empty values'
);
}
@ -441,9 +441,9 @@ EOD;
$section = $config->getSection('garbage');
$section->foobar = null;
$iniWriter = new IniWriter($config, $filename);
$this->assertEquals(
0,
preg_match('/foobar/', $iniWriter->render()),
$this->assertNotContains(
'foobar',
$iniWriter->render(),
'IniWriter doesn\'t remove section keys with null values'
);