public function ReaderTest::testFindPattern in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/symfony/css-selector/Tests/Parser/ReaderTest.php \Symfony\Component\CssSelector\Tests\Parser\ReaderTest::testFindPattern()
File
- vendor/
symfony/ css-selector/ Tests/ Parser/ ReaderTest.php, line 67
Class
Namespace
Symfony\Component\CssSelector\Tests\ParserCode
public function testFindPattern() {
$reader = new Reader('hello');
$this
->assertFalse($reader
->findPattern('/world/'));
$this
->assertEquals(array(
'hello',
'h',
), $reader
->findPattern('/^([a-z]).*/'));
$this
->assignPosition($reader, 2);
$this
->assertFalse($reader
->findPattern('/^h.*/'));
$this
->assertEquals(array(
'llo',
), $reader
->findPattern('/^llo$/'));
}