public function testCrawlBFSMaxQueueSize() { $this->spider->getQueueManager()->setTraversalAlgorithm(InMemoryQueueManager::ALGORITHM_BREADTH_FIRST); $this->spider->getDiscovererSet()->maxDepth = 1000; $this->spider->getDownloader()->setDownloadLimit(3); $this->spider->crawl(); $expected = array($this->linkA, $this->linkB, $this->linkC); $this->assertEquals($expected, $this->statsHandler->getPersisted()); }