You are here

public function PHP_Token_NamespaceTest::testGetEndLineWithUnscopedNamespace in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php \PHP_Token_NamespaceTest::testGetEndLineWithUnscopedNamespace()

File

vendor/phpunit/php-token-stream/tests/Token/NamespaceTest.php, line 51

Class

PHP_Token_NamespaceTest
Tests for the PHP_Token_NAMESPACE class.

Code

public function testGetEndLineWithUnscopedNamespace() {
  $tokenStream = new PHP_Token_Stream(TEST_FILES_PATH . 'classInNamespace.php');
  foreach ($tokenStream as $token) {
    if ($token instanceof PHP_Token_NAMESPACE) {
      $this
        ->assertSame(2, $token
        ->getEndLine());
    }
  }
}