mirror of
https://github.com/barryvdh/ReflectionDocBlock.git
synced 2026-08-18 01:57:13 +00:00
Make split platform independend
This commit is contained in:
@@ -134,7 +134,7 @@ class DocBlockFactoryTest extends TestCase
|
||||
$docblock = $fixture->create($given);
|
||||
|
||||
$this->assertSame($summary, $docblock->getSummary());
|
||||
$this->assertEquals(new Description($description), $docblock->getDescription());
|
||||
$this->assertEquals(new Description(str_replace(PHP_EOL, "\n", $description)), $docblock->getDescription());
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -159,12 +159,7 @@ class DocBlockFactoryTest extends TestCase
|
||||
*/
|
||||
DOCBLOCK;
|
||||
|
||||
$description = <<<DESCRIPTION
|
||||
This is a multiline Description
|
||||
that contains a code block.
|
||||
|
||||
See here: a CodeBlock
|
||||
DESCRIPTION;
|
||||
$description = "This is a multiline Description\nthat contains a code block.\n\n See here: a CodeBlock";
|
||||
|
||||
$docblock = $fixture->create($given);
|
||||
|
||||
@@ -180,14 +175,9 @@ DESCRIPTION;
|
||||
*/
|
||||
public function testTagsAreInterpretedUsingFactory(): void
|
||||
{
|
||||
$tagString = <<<TAG
|
||||
@author Mike van Riel <[email protected]> This is with
|
||||
multiline description.
|
||||
TAG;
|
||||
|
||||
$tag = m::mock(Tag::class);
|
||||
$tagFactory = m::mock(TagFactory::class);
|
||||
$tagFactory->shouldReceive('create')->with($tagString, m::type(Context::class))->andReturn($tag);
|
||||
$tagFactory->shouldReceive('create')->with(m::any(), m::type(Context::class))->andReturn($tag);
|
||||
|
||||
$fixture = new DocBlockFactory(new DescriptionFactory($tagFactory), $tagFactory);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user