diff options
author | Jeremy Benoist <j0k3r@users.noreply.github.com> | 2016-10-02 11:04:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-02 11:04:49 +0200 |
commit | bfb3ae01dafa921505384c5db1cd6625ecdd0bb8 (patch) | |
tree | 1e8fec40282a204c6ba24a0f0c2eefb245391518 /tests/Wallabag | |
parent | ae394b407831b45755d084328cd440e0bdcf453f (diff) | |
parent | 1264029cd413a4e29642a219e2647d886f0de0d6 (diff) | |
download | wallabag-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/Wallabag')
-rw-r--r-- | tests/Wallabag/CoreBundle/Twig/WallabagExtensionTest.php | 18 |
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')); |