You are here

public function TokenizerTest::testWhitespace in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php \Masterminds\HTML5\Tests\Parser\TokenizerTest::testWhitespace()

File

vendor/masterminds/html5/test/HTML5/Parser/TokenizerTest.php, line 78

Class

TokenizerTest

Namespace

Masterminds\HTML5\Tests\Parser

Code

public function testWhitespace() {
  $spaces = '    ';
  list($tok, $events) = $this
    ->createTokenizer($spaces);
  $tok
    ->parse();
  $this
    ->assertEquals(2, $events
    ->depth());
  $e1 = $events
    ->get(0);
  $this
    ->assertEquals('text', $e1['name']);
  $this
    ->assertEquals($spaces, $e1['data'][0]);
}