summaryrefslogtreecommitdiff
path: root/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php')
-rw-r--r--vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php b/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php
index 0abfb3ce..ddf77902 100644
--- a/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php
+++ b/vendor/symfony/console/Tests/Formatter/OutputFormatterStyleTest.php
@@ -11,9 +11,10 @@
namespace Symfony\Component\Console\Tests\Formatter;
+use PHPUnit\Framework\TestCase;
use Symfony\Component\Console\Formatter\OutputFormatterStyle;
-class OutputFormatterStyleTest extends \PHPUnit_Framework_TestCase
+class OutputFormatterStyleTest extends TestCase
{
public function testConstructor()
{
@@ -40,7 +41,7 @@ class OutputFormatterStyleTest extends \PHPUnit_Framework_TestCase
$style->setForeground('default');
$this->assertEquals("\033[39mfoo\033[39m", $style->apply('foo'));
- $this->setExpectedException('InvalidArgumentException');
+ $this->{method_exists($this, $_ = 'expectException') ? $_ : 'setExpectedException'}('InvalidArgumentException');
$style->setForeground('undefined-color');
}
@@ -57,7 +58,7 @@ class OutputFormatterStyleTest extends \PHPUnit_Framework_TestCase
$style->setBackground('default');
$this->assertEquals("\033[49mfoo\033[49m", $style->apply('foo'));
- $this->setExpectedException('InvalidArgumentException');
+ $this->{method_exists($this, $_ = 'expectException') ? $_ : 'setExpectedException'}('InvalidArgumentException');
$style->setBackground('undefined-color');
}