Hide expected 'error_log' while running TU (clean PHPUnit log)

This commit is contained in:
ArthurHoaro 2016-07-23 14:16:07 +02:00
parent 0c4c7ae818
commit 87f9f4f9b7
2 changed files with 6 additions and 0 deletions

View file

@ -75,9 +75,12 @@ public function testGetLatestGitVersionCode()
*/
public function testGetLatestGitVersionCodeInvalidUrl()
{
$oldlog = ini_get('error_log');
ini_set('error_log', '/dev/null');
$this->assertFalse(
ApplicationUtils::getLatestGitVersionCode('htttp://null.io', 1)
);
ini_set('error_log', $oldlog);
}
/**

View file

@ -64,10 +64,13 @@ public function testPurgeCachedPages()
*/
public function testPurgeCachedPagesMissingDir()
{
$oldlog = ini_get('error_log');
ini_set('error_log', '/dev/null');
$this->assertEquals(
'Cannot purge sandbox/dummycache_missing: no directory',
purgeCachedPages(self::$testCacheDir.'_missing')
);
ini_set('error_log', $oldlog);
}
/**