Explorar el Código

Merge remote branch 'Seldaek/loggerinterface'

* Seldaek/loggerinterface:
  [HttpKernel] Removed log() from the LoggerInterface as the priority can not be safely determined across implementations
  [HttpKernel] Prevent errors leaking out in the console on windows
Fabien Potencier hace 14 años
padre
commit
f08fc7aae2

+ 0 - 2
src/Symfony/Component/HttpKernel/Log/LoggerInterface.php

@@ -18,8 +18,6 @@ namespace Symfony\Component\HttpKernel\Log;
  */
 interface LoggerInterface
 {
-    function log($message, $priority);
-
     function emerg($message);
 
     function alert($message);

+ 5 - 5
tests/Symfony/Tests/Component/HttpKernel/Debug/ExceptionListenerTest.php

@@ -45,9 +45,9 @@ class ExceptionListenerTest extends \PHPUnit_Framework_TestCase
      */
     public function testHandleWithoutLogger($event, $event2)
     {
-        //store the current error_log, and set the new one to dev/null
-        $error_log = ini_get('error_log');
-        ini_set('error_log', '/dev/null');
+        //store the current log_errors, and disable it temporarily
+        $logErrors = ini_get('log_errors');
+        ini_set('log_errors', 'Off');
 
         $l = new ExceptionListener('foo');
         $l->onCoreException($event);
@@ -60,8 +60,8 @@ class ExceptionListenerTest extends \PHPUnit_Framework_TestCase
             $this->assertSame('foo', $e->getMessage());
         }
 
-        //restore the old error_log
-        ini_set('error_log', $error_log);
+        //restore the old log_errors setting
+        ini_set('log_errors', $logErrors);
     }
 
     /**