X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=tests%2Fphpunit%2Fincludes%2Fobjectcache%2FRESTBagOStuffTest.php;h=66754fc93f05b89ba5395bf4fb0b6089c8f63b34;hp=ebeb1092a6a2f17be7ec627d75340a659fda1090;hb=6b3e5511fb848890f174690885e748b90389c0b8;hpb=99dbf4e1d4d7f18e02935bdb8cd3be4413ffe729 diff --git a/tests/phpunit/includes/objectcache/RESTBagOStuffTest.php b/tests/phpunit/includes/objectcache/RESTBagOStuffTest.php index ebeb1092a6..66754fc93f 100644 --- a/tests/phpunit/includes/objectcache/RESTBagOStuffTest.php +++ b/tests/phpunit/includes/objectcache/RESTBagOStuffTest.php @@ -1,6 +1,8 @@ client = - $this->getMockBuilder( 'MultiHttpClient' ) + $this->getMockBuilder( MultiHttpClient::class ) ->setConstructorArgs( [ [] ] ) ->setMethods( [ 'run' ] ) ->getMock(); @@ -27,7 +29,7 @@ class RESTBagOStuffTest extends MediaWikiTestCase { $this->client->expects( $this->once() )->method( 'run' )->with( [ 'method' => 'GET', 'url' => 'http://test/rest/42xyz42' - // list( $rcode, $rdesc, $rhdrs, $rbody, $rerr ) + // list( $rcode, $rdesc, $rhdrs, $rbody, $rerr ) ] )->willReturn( [ 200, 'OK', [], 's:8:"somedata";', 0 ] ); $result = $this->bag->get( '42xyz42' ); $this->assertEquals( 'somedata', $result ); @@ -69,7 +71,7 @@ class RESTBagOStuffTest extends MediaWikiTestCase { $this->client->expects( $this->once() )->method( 'run' )->with( [ 'method' => 'PUT', 'url' => 'http://test/rest/42xyz42', - 'body' => 's:8:"postdata";' + 'body' => 's:8:"postdata";' // list( $rcode, $rdesc, $rhdrs, $rbody, $rerr ) ] )->willReturn( [ 200, 'OK', [], 'Done', 0 ] ); $result = $this->bag->set( '42xyz42', 'postdata' );