aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authorJeremy Benoist <j0k3r@users.noreply.github.com>2016-10-02 11:04:49 +0200
committerGitHub <noreply@github.com>2016-10-02 11:04:49 +0200
commitbfb3ae01dafa921505384c5db1cd6625ecdd0bb8 (patch)
tree1e8fec40282a204c6ba24a0f0c2eefb245391518 /tests
parentae394b407831b45755d084328cd440e0bdcf453f (diff)
parent1264029cd413a4e29642a219e2647d886f0de0d6 (diff)
downloadwallabag-bfb3ae01dafa921505384c5db1cd6625ecdd0bb8.tar.gz
wallabag-bfb3ae01dafa921505384c5db1cd6625ecdd0bb8.tar.zst
wallabag-bfb3ae01dafa921505384c5db1cd6625ecdd0bb8.zip
Merge pull request #2323 from wallabag/footer-stats
Add simple stats in footer
Diffstat (limited to 'tests')
-rw-r--r--tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php18
1 files changed, 17 insertions, 1 deletions
diff --git a/tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php b/tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php
index 8ec2a75a..b1c8c946 100644
--- a/tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php
+++ b/tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php
@@ -8,7 +8,23 @@ class WallabagExtensionTest extends \PHPUnit_Framework_TestCase
8{ 8{
9 public function testRemoveWww() 9 public function testRemoveWww()
10 { 10 {
11 $extension = new WallabagExtension(); 11 $entryRepository = $this->getMockBuilder('Wallabag\CoreBundle\Repository\EntryRepository')
12 ->disableOriginalConstructor()
13 ->getMock();
14
15 $tagRepository = $this->getMockBuilder('Wallabag\CoreBundle\Repository\TagRepository')
16 ->disableOriginalConstructor()
17 ->getMock();
18
19 $tokenStorage = $this->getMockBuilder('Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface')
20 ->disableOriginalConstructor()
21 ->getMock();
22
23 $translator = $this->getMockBuilder('Symfony\Component\Translation\TranslatorInterface')
24 ->disableOriginalConstructor()
25 ->getMock();
26
27 $extension = new WallabagExtension($entryRepository, $tagRepository, $tokenStorage, 0, $translator);
12 28
13 $this->assertEquals('lemonde.fr', $extension->removeWww('www.lemonde.fr')); 29 $this->assertEquals('lemonde.fr', $extension->removeWww('www.lemonde.fr'));
14 $this->assertEquals('lemonde.fr', $extension->removeWww('lemonde.fr')); 30 $this->assertEquals('lemonde.fr', $extension->removeWww('lemonde.fr'));