public function DescriptionTest::testNestedLiteralClosingDelimiter in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/phpdocumentor/reflection-docblock/tests/phpDocumentor/Reflection/DocBlock/DescriptionTest.php \phpDocumentor\Reflection\DocBlock\DescriptionTest::testNestedLiteralClosingDelimiter()
File
- vendor/
phpdocumentor/ reflection-docblock/ tests/ phpDocumentor/ Reflection/ DocBlock/ DescriptionTest.php, line 174
Class
- DescriptionTest
- Test class for \phpDocumentor\Reflection\DocBlock\Description
Namespace
phpDocumentor\Reflection\DocBlockCode
public function testNestedLiteralClosingDelimiter() {
$fixture = <<<LONGDESC
This is text for a description with {@internal inline tag with {} that is not an
inline tag}.
LONGDESC;
$object = new Description($fixture);
$this
->assertSame($fixture, $object
->getContents());
$parsedContents = $object
->getParsedContents();
$this
->assertCount(3, $parsedContents);
$this
->assertSame('This is text for a description with ', $parsedContents[0]);
$this
->assertInstanceOf(__NAMESPACE__ . '\\Tag', $parsedContents[1]);
$this
->assertSame('.', $parsedContents[2]);
$this
->assertSame(array(
'inline tag with } that is not an
inline tag',
), $parsedContents[1]
->getParsedDescription());
}