]> source.dussan.org Git - nextcloud-server.git/commitdiff
Mock logger 358/head
authorRoeland Jago Douma <roeland@famdouma.nl>
Sun, 10 Jul 2016 12:19:55 +0000 (14:19 +0200)
committerRoeland Jago Douma <roeland@famdouma.nl>
Mon, 11 Jul 2016 06:50:30 +0000 (08:50 +0200)
tests/lib/AppFramework/Routing/RoutingTest.php

index ce0866f05117885b6a60782ac42878763c0d60df..52a5eb33ba9e661999926d55b4913e5f7f6ec516 100644 (file)
@@ -76,7 +76,7 @@ class RoutingTest extends \Test\TestCase
                // router mock
                $router = $this->getMockBuilder('\OC\Route\Router')
                        ->setMethods(['create'])
-                       ->setConstructorArgs([\OC::$server->getLogger()])
+                       ->setConstructorArgs([$this->getMockBuilder('\OCP\ILogger')->getMock()])
                        ->getMock();
 
                // load route configuration
@@ -129,7 +129,7 @@ class RoutingTest extends \Test\TestCase
                // router mock
                $router = $this->getMockBuilder('\OC\Route\Router')
                        ->setMethods(['create'])
-                       ->setConstructorArgs([\OC::$server->getLogger()])
+                       ->setConstructorArgs([$this->getMockBuilder('\OCP\ILogger')->getMock()])
                        ->getMock();
 
                // we expect create to be called once:
@@ -156,7 +156,7 @@ class RoutingTest extends \Test\TestCase
                // router mock
                $router = $this->getMockBuilder('\OC\Route\Router')
                        ->setMethods(['create'])
-                       ->setConstructorArgs([\OC::$server->getLogger()])
+                       ->setConstructorArgs([$this->getMockBuilder('\OCP\ILogger')->getMock()])
                        ->getMock();
 
                // route mocks