diff options
Diffstat (limited to 'tests/unit/fetcher')
-rw-r--r-- | tests/unit/fetcher/FeedFetcherTest.php | 11 | ||||
-rw-r--r-- | tests/unit/fetcher/FetcherTest.php | 11 |
2 files changed, 20 insertions, 2 deletions
diff --git a/tests/unit/fetcher/FeedFetcherTest.php b/tests/unit/fetcher/FeedFetcherTest.php index e1a3997ac..2c743500a 100644 --- a/tests/unit/fetcher/FeedFetcherTest.php +++ b/tests/unit/fetcher/FeedFetcherTest.php @@ -319,6 +319,17 @@ class FeedFetcherTest extends \PHPUnit_Framework_TestCase { $this->assertEquals([$feed, [$item]], $result); } + public function testFullText() { + $this->setUpReader($this->url); + + $feed = $this->createFeed(); + $item = $this->createItem(); + $this->parser->expects($this->once()) + ->method('enableContentGrabber'); + $this->expectFeed('getItems', [$this->item]); + $this->fetcher->fetch($this->url, false, null, null, true); + } + public function testNoFavicon() { $this->setUpReader($this->url); diff --git a/tests/unit/fetcher/FetcherTest.php b/tests/unit/fetcher/FetcherTest.php index 1ab81fc1e..5b9efc920 100644 --- a/tests/unit/fetcher/FetcherTest.php +++ b/tests/unit/fetcher/FetcherTest.php @@ -44,9 +44,16 @@ class FetcherTest extends \PHPUnit_Framework_TestCase { ->method('canHandle') ->with($this->equalTo($url)) ->will($this->returnValue(true)); + $mockFetcher->expects($this->once()) + ->method('fetch') + ->with($this->equalTo($url), + $this->equalTo(true), + $this->equalTo(1), + $this->equalTo(2), + $this->equalTo(3)); $this->fetcher->registerFetcher($mockFetcher); - $this->fetcher->fetch($url); + $this->fetcher->fetch($url, true, 1, 2, 3); } @@ -127,4 +134,4 @@ class FetcherTest extends \PHPUnit_Framework_TestCase { } -}
\ No newline at end of file +} |