apply coding standard to code

This commit is contained in:
TomasVotruba
2018-01-02 13:40:57 +01:00
parent 89a0935960
commit 1c8f795c0e
45 changed files with 212 additions and 216 deletions
@@ -43,7 +43,7 @@ class DescriptionFactoryTest extends TestCase
$tagFactory = m::mock(TagFactory::class);
$tagFactory->shouldReceive('create')->never();
$factory = new DescriptionFactory($tagFactory);
$factory = new DescriptionFactory($tagFactory);
$description = $factory->create($contents, new Context(''));
$this->assertSame($contents, $description->render());
@@ -60,7 +60,7 @@ class DescriptionFactoryTest extends TestCase
$tagFactory = m::mock(TagFactory::class);
$tagFactory->shouldReceive('create')->never();
$factory = new DescriptionFactory($tagFactory);
$factory = new DescriptionFactory($tagFactory);
$description = $factory->create($contents, new Context(''));
$this->assertSame($expected, $description->render());
@@ -77,15 +77,15 @@ class DescriptionFactoryTest extends TestCase
*/
public function testDescriptionCanParseAStringWithInlineTag(): void
{
$contents = 'This is text for a {@link http://phpdoc.org/ description} that uses an inline tag.';
$context = new Context('');
$contents = 'This is text for a {@link http://phpdoc.org/ description} that uses an inline tag.';
$context = new Context('');
$tagFactory = m::mock(TagFactory::class);
$tagFactory->shouldReceive('create')
->once()
->with('@link http://phpdoc.org/ description', $context)
->andReturn(new Link('http://phpdoc.org/', new Description('description')));
$factory = new DescriptionFactory($tagFactory);
$factory = new DescriptionFactory($tagFactory);
$description = $factory->create($contents, $context);
$this->assertSame($contents, $description->render());
@@ -102,15 +102,15 @@ class DescriptionFactoryTest extends TestCase
*/
public function testDescriptionCanParseAStringStartingWithInlineTag(): void
{
$contents = '{@link http://phpdoc.org/ This} is text for a description that starts with an inline tag.';
$context = new Context('');
$contents = '{@link http://phpdoc.org/ This} is text for a description that starts with an inline tag.';
$context = new Context('');
$tagFactory = m::mock(TagFactory::class);
$tagFactory->shouldReceive('create')
->once()
->with('@link http://phpdoc.org/ This', $context)
->andReturn(new Link('http://phpdoc.org/', new Description('This')));
$factory = new DescriptionFactory($tagFactory);
$factory = new DescriptionFactory($tagFactory);
$description = $factory->create($contents, $context);
$this->assertSame($contents, $description->render());
@@ -123,7 +123,7 @@ class DescriptionFactoryTest extends TestCase
*/
public function testIfSuperfluousStartingSpacesAreRemoved(): void
{
$factory = new DescriptionFactory(m::mock(TagFactory::class));
$factory = new DescriptionFactory(m::mock(TagFactory::class));
$descriptionText = <<<DESCRIPTION
This is a multiline
description that you commonly