public function CrawlerTest::testFirst in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/dom-crawler/Tests/CrawlerTest.php \Symfony\Component\DomCrawler\Tests\CrawlerTest::testFirst()
File
- vendor/
symfony/ dom-crawler/ Tests/ CrawlerTest.php, line 836
Class
Namespace
Symfony\Component\DomCrawler\TestsCode
public function testFirst() {
$crawler = $this
->createTestCrawler()
->filterXPath('//li');
$this
->assertNotSame($crawler, $crawler
->first(), '->first() returns a new instance of a crawler');
$this
->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler, '->first() returns a new instance of a crawler');
$this
->assertEquals('One', $crawler
->first()
->text());
}