X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2FMediaWikiTestCase.php;h=419ff00f85357526caa6ad9077e700c845470534;hb=a98ef5dd96f8c20d182e554848655ac3c8b051f9;hp=37f76ff4d15e991edef5145bf36f19d6343debdf;hpb=5eaf2e1f15b03a3665d89176311c07d4c418e55d;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/MediaWikiTestCase.php b/tests/phpunit/MediaWikiTestCase.php index 37f76ff4d1..419ff00f85 100644 --- a/tests/phpunit/MediaWikiTestCase.php +++ b/tests/phpunit/MediaWikiTestCase.php @@ -439,7 +439,7 @@ abstract class MediaWikiTestCase extends PHPUnit_Framework_TestCase { * @return string Absolute name of the temporary file */ protected function getNewTempFile() { - $fileName = tempnam( wfTempDir(), 'MW_PHPUnit_' . get_class( $this ) . '_' ); + $fileName = tempnam( wfTempDir(), 'MW_PHPUnit_' . static::class . '_' ); $this->tmpFiles[] = $fileName; return $fileName; @@ -1304,8 +1304,7 @@ abstract class MediaWikiTestCase extends PHPUnit_Framework_TestCase { if ( isset( $compatibility[$func] ) ) { return call_user_func_array( [ $this, $compatibility[$func] ], $args ); } else { - throw new MWException( "Called non-existent $func method on " - . get_class( $this ) ); + throw new MWException( "Called non-existent $func method on " . static::class ); } }