diff --git a/tests/Composer/Test/Repository/Vcs/GitDriverTest.php b/tests/Composer/Test/Repository/Vcs/GitDriverTest.php index 1fb52f3be..d40366158 100644 --- a/tests/Composer/Test/Repository/Vcs/GitDriverTest.php +++ b/tests/Composer/Test/Repository/Vcs/GitDriverTest.php @@ -164,7 +164,7 @@ GIT; public function testFileGetContentInvalidIdentifier(): void { - $this->expectException('\RuntimeException'); + self::expectException('\RuntimeException'); $process = $this->getProcessExecutorMock(); $io = $this->getMockBuilder('Composer\IO\IOInterface')->getMock(); diff --git a/tests/Composer/Test/Repository/Vcs/HgDriverTest.php b/tests/Composer/Test/Repository/Vcs/HgDriverTest.php index a65ad1526..812ccbc7e 100644 --- a/tests/Composer/Test/Repository/Vcs/HgDriverTest.php +++ b/tests/Composer/Test/Repository/Vcs/HgDriverTest.php @@ -104,7 +104,7 @@ HG_BOOKMARKS; public function testFileGetContentInvalidIdentifier(): void { - $this->expectException('\RuntimeException'); + self::expectException('\RuntimeException'); $process = $this->getProcessExecutorMock(); $driver = new HgDriver(array('url' => 'https://example.org/acme.git'), $this->io, $this->config, $this->getMockBuilder('Composer\Util\HttpDownloader')->disableOriginalConstructor()->getMock(), $process);