public function TokenStreamTest::testSkipWhitespace in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php \Symfony\Component\CssSelector\Tests\Parser\TokenStreamTest::testSkipWhitespace()
File
- vendor/
symfony/ css-selector/ Tests/ Parser/ TokenStreamTest.php, line 82
Class
Namespace
Symfony\Component\CssSelector\Tests\ParserCode
public function testSkipWhitespace() {
$stream = new TokenStream();
$stream
->push($t1 = new Token(Token::TYPE_IDENTIFIER, 'h1', 0));
$stream
->push($t2 = new Token(Token::TYPE_WHITESPACE, ' ', 2));
$stream
->push($t3 = new Token(Token::TYPE_IDENTIFIER, 'h1', 3));
$stream
->skipWhitespace();
$this
->assertSame($t1, $stream
->getNext());
$stream
->skipWhitespace();
$this
->assertSame($t3, $stream
->getNext());
}