You are here

public function ReaderTest::testGetOffset in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/css-selector/Tests/Parser/ReaderTest.php \Symfony\Component\CssSelector\Tests\Parser\ReaderTest::testGetOffset()

File

vendor/symfony/css-selector/Tests/Parser/ReaderTest.php, line 56

Class

ReaderTest

Namespace

Symfony\Component\CssSelector\Tests\Parser

Code

public function testGetOffset() {
  $reader = new Reader('hello');
  $this
    ->assertEquals(2, $reader
    ->getOffset('ll'));
  $this
    ->assertFalse($reader
    ->getOffset('w'));
  $this
    ->assignPosition($reader, 2);
  $this
    ->assertEquals(0, $reader
    ->getOffset('ll'));
  $this
    ->assertFalse($reader
    ->getOffset('he'));
}