From b4e6630c1da13b825d7f07bf424d5d8ae7627809 Mon Sep 17 00:00:00 2001 From: vladar Date: Thu, 26 Jan 2017 18:48:23 +0700 Subject: [PATCH] PHPUnit: Replaced deprecated method getMock() with getMockBuilder() --- tests/ServerTest.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/ServerTest.php b/tests/ServerTest.php index f249eb0..27d4753 100644 --- a/tests/ServerTest.php +++ b/tests/ServerTest.php @@ -509,7 +509,11 @@ class ServerTest extends \PHPUnit_Framework_TestCase public function testHandleRequest() { - $mock = $this->getMock('GraphQL\Server', ['readInput', 'produceOutput']); + $mock = $this->getMockBuilder('GraphQL\Server') + ->setMethods(['readInput', 'produceOutput']) + ->getMock() + ; + $mock->method('readInput') ->will($this->returnValue(json_encode(['query' => '{err}'])));