]> git.immae.eu Git - github/shaarli/Shaarli.git/commitdiff
Hide expected 'error_log' while running TU (clean PHPUnit log) 605/head
authorArthurHoaro <arthur@hoa.ro>
Sat, 23 Jul 2016 12:16:07 +0000 (14:16 +0200)
committerArthurHoaro <arthur@hoa.ro>
Sat, 23 Jul 2016 12:16:07 +0000 (14:16 +0200)
tests/ApplicationUtilsTest.php
tests/CacheTest.php

index c37a94f0944f08f9da242cdadf6211d8a6619835..861b8d4e506533c1f155f6542018692f64aaea67 100644 (file)
@@ -75,9 +75,12 @@ class ApplicationUtilsTest extends PHPUnit_Framework_TestCase
      */
     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);
     }
 
     /**
index 26c432254a9d0e966d97f8a949681f035f808d7a..992e26a5502cea6afc15cc9756f85c7e507089d0 100644 (file)
@@ -64,10 +64,13 @@ class CacheTest extends PHPUnit_Framework_TestCase
      */
     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);
     }
 
     /**