Skip to content

Commit

Permalink
fixed some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Nyholm committed Jan 10, 2019
1 parent c56c759 commit 04c99d3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/Api/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
use GuzzleHttp\Psr7\Request;
use GuzzleHttp\Psr7\Response;
use Mailgun\Hydrator\ModelHydrator;
use Psr\Http\Client\ClientInterface;
use Psr\Http\Message\ResponseInterface;

/**
Expand Down Expand Up @@ -49,7 +50,7 @@ abstract protected function getApiClass();
protected function getApiMock($httpClient = null, $requestClient = null, $hydrator = null)
{
if (null === $httpClient) {
$httpClient = $this->getMockBuilder('Http\Client\HttpClient')
$httpClient = $this->getMockBuilder(ClientInterface::class)
->setMethods(['sendRequest'])
->getMock();
$httpClient
Expand Down Expand Up @@ -79,7 +80,7 @@ protected function getApiMock($httpClient = null, $requestClient = null, $hydrat
*/
protected function getApiInstance($apiKey = null)
{
$httpClient = $this->getMockBuilder('Http\Client\HttpClient')
$httpClient = $this->getMockBuilder(ClientInterface::class)
->setMethods(['sendRequest'])
->getMock();
$httpClient
Expand Down

0 comments on commit 04c99d3

Please sign in to comment.