mirror of
https://github.com/composer/composer
synced 2025-05-09 08:32:56 +00:00
Update tests
This commit is contained in:
parent
754f2868fb
commit
df8f9f05a3
2 changed files with 40 additions and 23 deletions
|
@ -210,6 +210,14 @@ abstract class TestCase extends \PHPUnit\Framework\TestCase
|
|||
return new ApplicationTester($application);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trims the entire string but also the trailing spaces off of every line
|
||||
*/
|
||||
protected function trimLines(string $str): string
|
||||
{
|
||||
return trim(Preg::replace('{^(.*?) *$}m', '$1', $str));
|
||||
}
|
||||
|
||||
protected static function getVersionParser(): VersionParser
|
||||
{
|
||||
if (!self::$parser) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue