Skip to content

Commit bfc0b5c

Browse files
committed
Cover both old and new PHPUnit versions
1 parent e12e5f9 commit bfc0b5c

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

tests/Phug/DevTool/ApplicationTest.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,11 @@ public function testRunVendorCommand()
112112
*/
113113
public function testGetShellCommandPathException()
114114
{
115-
self::expectException(RuntimeException::class);
116-
self::expectExceptionMessage('The given command [vendor/bin/doNotExists] was not found');
115+
if (method_exists(self::class, 'expectException')) {
116+
self::expectException(RuntimeException::class);
117+
self::expectExceptionMessage('The given command [vendor/bin/doNotExists] was not found');
118+
}
119+
117120
$app = new Application();
118121
$app->runVendorCommand('doNotExists');
119122
}

0 commit comments

Comments
 (0)