You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$this->assertNotSame($crawler->slice(), $crawler, '->slice() returns a new instance of a crawler');
293
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->slice(), '->slice() returns a new instance of a crawler');
293
+
$this->assertInstanceOf(Crawler::class, $crawler->slice(), '->slice() returns a new instance of a crawler');
294
294
295
295
$this->assertCount(3, $crawler->slice(), '->slice() does not slice the nodes in the list if any param is entered');
296
296
$this->assertCount(1, $crawler->slice(1, 1), '->slice() slices the nodes in the list');
@@ -303,7 +303,7 @@ public function testReduce()
303
303
return1 !== $i;
304
304
});
305
305
$this->assertNotSame($nodes, $crawler, '->reduce() returns a new instance of a crawler');
306
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $nodes, '->reduce() returns a new instance of a crawler');
306
+
$this->assertInstanceOf(Crawler::class, $nodes, '->reduce() returns a new instance of a crawler');
307
307
308
308
$this->assertCount(2, $nodes, '->reduce() filters the nodes in the list');
309
309
}
@@ -412,7 +412,7 @@ public function testFilterXPath()
412
412
{
413
413
$crawler = $this->createTestCrawler();
414
414
$this->assertNotSame($crawler, $crawler->filterXPath('//li'), '->filterXPath() returns a new instance of a crawler');
415
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->filterXPath('//li'), '->filterXPath() returns a new instance of a crawler');
415
+
$this->assertInstanceOf(Crawler::class, $crawler->filterXPath('//li'), '->filterXPath() returns a new instance of a crawler');
@@ -632,7 +632,7 @@ public function testSelectLink()
632
632
{
633
633
$crawler = $this->createTestCrawler();
634
634
$this->assertNotSame($crawler, $crawler->selectLink('Foo'), '->selectLink() returns a new instance of a crawler');
635
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->selectLink('Foo'), '->selectLink() returns a new instance of a crawler');
635
+
$this->assertInstanceOf(Crawler::class, $crawler->selectLink('Foo'), '->selectLink() returns a new instance of a crawler');
636
636
637
637
$this->assertCount(1, $crawler->selectLink('Fabien\'s Foo'), '->selectLink() selects links by the node values');
638
638
$this->assertCount(1, $crawler->selectLink('Fabien\'s Bar'), '->selectLink() selects links by the alt attribute of a clickable image');
@@ -651,7 +651,7 @@ public function testSelectImage()
651
651
{
652
652
$crawler = $this->createTestCrawler();
653
653
$this->assertNotSame($crawler, $crawler->selectImage('Bar'), '->selectImage() returns a new instance of a crawler');
654
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->selectImage('Bar'), '->selectImage() returns a new instance of a crawler');
654
+
$this->assertInstanceOf(Crawler::class, $crawler->selectImage('Bar'), '->selectImage() returns a new instance of a crawler');
655
655
656
656
$this->assertCount(1, $crawler->selectImage('Fabien\'s Bar'), '->selectImage() selects images by alt attribute');
657
657
$this->assertCount(2, $crawler->selectImage('Fabien"s Bar'), '->selectImage() selects images by alt attribute');
@@ -662,7 +662,7 @@ public function testSelectButton()
662
662
{
663
663
$crawler = $this->createTestCrawler();
664
664
$this->assertNotSame($crawler, $crawler->selectButton('FooValue'), '->selectButton() returns a new instance of a crawler');
665
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Crawler', $crawler->selectButton('FooValue'), '->selectButton() returns a new instance of a crawler');
665
+
$this->assertInstanceOf(Crawler::class, $crawler->selectButton('FooValue'), '->selectButton() returns a new instance of a crawler');
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Form', $crawler->form(), '->form() returns a Form instance');
833
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Form', $crawler2->form(), '->form() returns a Form instance');
832
+
$this->assertInstanceOf(\Symfony\Component\DomCrawler\Form::class, $crawler->form(), '->form() returns a Form instance');
833
+
$this->assertInstanceOf(\Symfony\Component\DomCrawler\Form::class, $crawler2->form(), '->form() returns a Form instance');
834
834
835
835
$this->assertEquals($crawler->form()->getFormNode()->getAttribute('id'), $crawler2->form()->getFormNode()->getAttribute('id'), '->form() works on elements with form attribute');
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Field\\InputFormField', $form->get('bar'), '->get() returns the field object associated with the given name');
685
+
$this->assertInstanceOf(\Symfony\Component\DomCrawler\Field\InputFormField::class, $form->get('bar'), '->get() returns the field object associated with the given name');
686
686
687
687
try {
688
688
$form->get('foo');
@@ -698,7 +698,7 @@ public function testAll()
698
698
699
699
$fields = $form->all();
700
700
$this->assertCount(1, $fields, '->all() return an array of form field objects');
701
-
$this->assertInstanceOf('Symfony\\Component\\DomCrawler\\Field\\InputFormField', $fields['bar'], '->all() return an array of form field objects');
701
+
$this->assertInstanceOf(\Symfony\Component\DomCrawler\Field\InputFormField::class, $fields['bar'], '->all() return an array of form field objects');
702
702
}
703
703
704
704
publicfunctiontestSubmitWithoutAFormButton()
@@ -741,14 +741,14 @@ public function testFormFieldRegistryAcceptAnyNames()
0 commit comments