]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Tests/Helper/ContentProxyTest.php
Errors in the automatic tagging do not prevent the entry from being added
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Tests / Helper / ContentProxyTest.php
index 1688a48a7c974e31ecf2943f30285656e3ee5329..f59edb0c9746ff55d7f122df4c3529f252defbc6 100644 (file)
@@ -29,7 +29,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase
                 'language' => '',
             ));
 
-        $proxy = new ContentProxy($graby, $tagger);
+        $proxy = new ContentProxy($graby, $tagger, $this->getLoggerMock());
         $entry = $proxy->updateEntry(new Entry(new User()), 'http://0.0.0.0');
 
         $this->assertEquals('http://0.0.0.0', $entry->getUrl());
@@ -67,7 +67,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase
                 ),
             ));
 
-        $proxy = new ContentProxy($graby, $tagger);
+        $proxy = new ContentProxy($graby, $tagger, $this->getLoggerMock());
         $entry = $proxy->updateEntry(new Entry(new User()), 'http://domain.io');
 
         $this->assertEquals('http://domain.io', $entry->getUrl());
@@ -106,7 +106,7 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase
                 ),
             ));
 
-        $proxy = new ContentProxy($graby, $tagger);
+        $proxy = new ContentProxy($graby, $tagger, $this->getLoggerMock());
         $entry = $proxy->updateEntry(new Entry(new User()), 'http://0.0.0.0');
 
         $this->assertEquals('http://1.1.1.1', $entry->getUrl());
@@ -126,4 +126,9 @@ class ContentProxyTest extends \PHPUnit_Framework_TestCase
             ->disableOriginalConstructor()
             ->getMock();
     }
+
+    private function getLoggerMock()
+    {
+        return $this->getMock('Psr\Log\LoggerInterface');
+    }
 }