diff options
author | ArthurHoaro <arthur@hoa.ro> | 2016-03-12 17:54:56 +0100 |
---|---|---|
committer | ArthurHoaro <arthur@hoa.ro> | 2016-03-25 19:17:59 +0100 |
commit | 89baf23ddfaf82cc663e26f76c307ef8e4bf4b02 (patch) | |
tree | 005002ac82329c5c03c2bb8e40bb59cb93b0e821 /tests/LinkFilterTest.php | |
parent | 82e3680203896f024958ae969e2c4fccee9682f4 (diff) | |
download | Shaarli-89baf23ddfaf82cc663e26f76c307ef8e4bf4b02.tar.gz Shaarli-89baf23ddfaf82cc663e26f76c307ef8e4bf4b02.tar.zst Shaarli-89baf23ddfaf82cc663e26f76c307ef8e4bf4b02.zip |
FeedBuilder unit tests
Diffstat (limited to 'tests/LinkFilterTest.php')
-rw-r--r-- | tests/LinkFilterTest.php | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/tests/LinkFilterTest.php b/tests/LinkFilterTest.php index ef1cc10a..f991a9c9 100644 --- a/tests/LinkFilterTest.php +++ b/tests/LinkFilterTest.php | |||
@@ -12,8 +12,6 @@ class LinkFilterTest extends PHPUnit_Framework_TestCase | |||
12 | */ | 12 | */ |
13 | protected static $linkFilter; | 13 | protected static $linkFilter; |
14 | 14 | ||
15 | protected static $NB_LINKS_REFDB = 7; | ||
16 | |||
17 | /** | 15 | /** |
18 | * Instanciate linkFilter with ReferenceLinkDB data. | 16 | * Instanciate linkFilter with ReferenceLinkDB data. |
19 | */ | 17 | */ |
@@ -29,7 +27,7 @@ class LinkFilterTest extends PHPUnit_Framework_TestCase | |||
29 | public function testFilter() | 27 | public function testFilter() |
30 | { | 28 | { |
31 | $this->assertEquals( | 29 | $this->assertEquals( |
32 | self::$NB_LINKS_REFDB, | 30 | ReferenceLinkDB::$NB_LINKS_TOTAL, |
33 | count(self::$linkFilter->filter('', '')) | 31 | count(self::$linkFilter->filter('', '')) |
34 | ); | 32 | ); |
35 | 33 | ||
@@ -40,12 +38,12 @@ class LinkFilterTest extends PHPUnit_Framework_TestCase | |||
40 | ); | 38 | ); |
41 | 39 | ||
42 | $this->assertEquals( | 40 | $this->assertEquals( |
43 | self::$NB_LINKS_REFDB, | 41 | ReferenceLinkDB::$NB_LINKS_TOTAL, |
44 | count(self::$linkFilter->filter(LinkFilter::$FILTER_TAG, '')) | 42 | count(self::$linkFilter->filter(LinkFilter::$FILTER_TAG, '')) |
45 | ); | 43 | ); |
46 | 44 | ||
47 | $this->assertEquals( | 45 | $this->assertEquals( |
48 | self::$NB_LINKS_REFDB, | 46 | ReferenceLinkDB::$NB_LINKS_TOTAL, |
49 | count(self::$linkFilter->filter(LinkFilter::$FILTER_TEXT, '')) | 47 | count(self::$linkFilter->filter(LinkFilter::$FILTER_TEXT, '')) |
50 | ); | 48 | ); |
51 | } | 49 | } |
@@ -383,7 +381,7 @@ class LinkFilterTest extends PHPUnit_Framework_TestCase | |||
383 | )) | 381 | )) |
384 | ); | 382 | ); |
385 | $this->assertEquals( | 383 | $this->assertEquals( |
386 | self::$NB_LINKS_REFDB, | 384 | ReferenceLinkDB::$NB_LINKS_TOTAL, |
387 | count(self::$linkFilter->filter( | 385 | count(self::$linkFilter->filter( |
388 | LinkFilter::$FILTER_TAG | LinkFilter::$FILTER_TEXT, | 386 | LinkFilter::$FILTER_TAG | LinkFilter::$FILTER_TEXT, |
389 | '' | 387 | '' |