X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Flibs%2FMemoizedCallableTest.php;h=9127a30f7a1260c96ae1698336e9df2a47d5360f;hb=9b670fb797813a8ed35750e2c83fe953a10f349e;hp=ba8af9352e15db3de08b8e44bfc1180aa7920c3e;hpb=58858df842f91d9ea1c9f9b6f3c767d8b204886b;p=lhc%2Fweb%2Fwiklou.git diff --git a/tests/phpunit/includes/libs/MemoizedCallableTest.php b/tests/phpunit/includes/libs/MemoizedCallableTest.php index ba8af9352e..9127a30f7a 100644 --- a/tests/phpunit/includes/libs/MemoizedCallableTest.php +++ b/tests/phpunit/includes/libs/MemoizedCallableTest.php @@ -24,7 +24,7 @@ class ArrayBackedMemoizedCallable extends MemoizedCallable { * PHP Unit tests for MemoizedCallable class. * @covers MemoizedCallable */ -class MemoizedCallableTest extends PHPUnit_Framework_TestCase { +class MemoizedCallableTest extends PHPUnit\Framework\TestCase { use MediaWikiCoversValidator; @@ -33,7 +33,7 @@ class MemoizedCallableTest extends PHPUnit_Framework_TestCase { * way as the original underlying callable. */ public function testReturnValuePassedThrough() { - $mock = $this->getMockBuilder( 'stdClass' ) + $mock = $this->getMockBuilder( stdClass::class ) ->setMethods( [ 'reverse' ] )->getMock(); $mock->expects( $this->any() ) ->method( 'reverse' ) @@ -47,10 +47,10 @@ class MemoizedCallableTest extends PHPUnit_Framework_TestCase { * Consecutive calls to the memoized callable with the same arguments * should result in just one invocation of the underlying callable. * - * @requires function apc_store/apcu_store + * @requires extension apcu */ public function testCallableMemoized() { - $observer = $this->getMockBuilder( 'stdClass' ) + $observer = $this->getMockBuilder( stdClass::class ) ->setMethods( [ 'computeSomething' ] )->getMock(); $observer->expects( $this->once() ) ->method( 'computeSomething' )