Mercurial > hg > cmmr2012-drupal-site
diff vendor/psy/psysh/test/Formatter/CodeFormatterTest.php @ 4:a9cd425dd02b
Update, including to Drupal core 8.6.10
author | Chris Cannam |
---|---|
date | Thu, 28 Feb 2019 13:11:55 +0000 |
parents | c75dbcec494b |
children |
line wrap: on
line diff
--- a/vendor/psy/psysh/test/Formatter/CodeFormatterTest.php Thu Feb 28 11:14:44 2019 +0000 +++ b/vendor/psy/psysh/test/Formatter/CodeFormatterTest.php Thu Feb 28 13:11:55 2019 +0000 @@ -22,7 +22,7 @@ public function testFormat($reflector, $expected) { $formatted = CodeFormatter::format($reflector); - $formattedWithoutColors = preg_replace('#' . chr(27) . '\[\d\d?m#', '', $formatted); + $formattedWithoutColors = \preg_replace('#' . \chr(27) . '\[\d\d?m#', '', $formatted); $this->assertEquals($expected, self::trimLines($formattedWithoutColors)); $this->assertNotEquals($expected, self::trimLines($formatted)); @@ -88,7 +88,7 @@ [new \ReflectionProperty('Psy\Test\Formatter\Fixtures\SomeClass', 'someProp')], ]; - if (version_compare(PHP_VERSION, '7.1.0', '>=')) { + if (\version_compare(PHP_VERSION, '7.1.0', '>=')) { $reflectors[] = [new \ReflectionClassConstant('Psy\Test\Formatter\Fixtures\SomeClass', 'SOME_CONST')]; } @@ -115,7 +115,7 @@ public function filenames() { - if (defined('HHVM_VERSION')) { + if (\defined('HHVM_VERSION')) { $this->markTestSkipped('We have issues with PHPUnit mocks on HHVM.'); } @@ -124,6 +124,6 @@ private static function trimLines($code) { - return rtrim(implode("\n", array_map('rtrim', explode("\n", $code)))); + return \rtrim(\implode("\n", \array_map('rtrim', \explode("\n", $code)))); } }