[Console] Fix tests on windows
This commit is contained in:
parent
7d0b30d579
commit
7b83b7221a
|
@ -44,6 +44,6 @@ list Lists commands
|
|||
|
||||
EOF;
|
||||
|
||||
$this->assertEquals(str_replace("\n", PHP_EOL, $output), $commandTester->getDisplay());
|
||||
$this->assertEquals($output, $commandTester->getDisplay(true));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,7 +54,7 @@ abstract class AbstractDescriptorTest extends \PHPUnit_Framework_TestCase
|
|||
$command->setHelp(str_replace('%command.full_name%', 'app/console %command.name%', $command->getHelp()));
|
||||
}
|
||||
|
||||
$this->assertEquals(trim($expectedDescription), trim($descriptor->describe($application)));
|
||||
$this->assertEquals(trim($expectedDescription), trim(str_replace(PHP_EOL, "\n", $descriptor->describe($application))));
|
||||
}
|
||||
|
||||
public function getDescribeInputArgumentTestData()
|
||||
|
|
|
@ -176,13 +176,13 @@ TABLE
|
|||
|
||||
protected function getOutputStream()
|
||||
{
|
||||
return new StreamOutput($this->stream);
|
||||
return new StreamOutput($this->stream, StreamOutput::VERBOSITY_NORMAL, false);
|
||||
}
|
||||
|
||||
protected function getOutputContent(StreamOutput $output)
|
||||
{
|
||||
rewind($output->getStream());
|
||||
|
||||
return stream_get_contents($output->getStream());
|
||||
return str_replace(PHP_EOL, "\n", stream_get_contents($output->getStream()));
|
||||
}
|
||||
}
|
||||
|
|
Reference in New Issue