public function StringInputStreamTest::testCharsUnitl in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php \Masterminds\HTML5\Tests\Parser\StringInputStreamTest::testCharsUnitl()
File
- vendor/masterminds/html5/test/HTML5/Parser/StringInputStreamTest.php, line 127
Class
- StringInputStreamTest
Namespace
Masterminds\HTML5\Tests\Parser
Code
public function testCharsUnitl() {
$text = "abcdefffffffghi";
$s = new StringInputStream($text);
$this
->assertEquals('', $s
->charsUntil('a'));
$this
->assertEquals('ab', $s
->charsUntil('w', 2));
$this
->assertEquals('cde', $s
->charsUntil('fzxv'));
$this
->assertEquals('fffff', $s
->charsUntil('g', 5));
$this
->assertEquals('ff', $s
->charsUntil('g'));
$this
->assertEquals('ghi', $s
->charsUntil('w', 9));
}