Issue #3220450 by xjm, phenaproxima: OEmbed ProviderRepositoryTest::testEmptyProviderList() does not interact with Guzzle's API correctly
(cherry picked from commit 2c57cbec9a
)
merge-requests/860/head
parent
0505e48cea
commit
0127852850
|
@ -3,6 +3,7 @@
|
|||
namespace Drupal\Tests\media\Functional;
|
||||
|
||||
use Drupal\media\OEmbed\ProviderException;
|
||||
use GuzzleHttp\Psr7\Utils;
|
||||
|
||||
/**
|
||||
* Tests the oEmbed provider repository.
|
||||
|
@ -28,7 +29,7 @@ class ProviderRepositoryTest extends MediaFunctionalTestBase {
|
|||
*/
|
||||
public function testEmptyProviderList($content) {
|
||||
$response = $this->prophesize('\GuzzleHttp\Psr7\Response');
|
||||
$response->getBody()->willReturn($content);
|
||||
$response->getBody()->willReturn(Utils::streamFor($content));
|
||||
|
||||
$client = $this->createMock('\GuzzleHttp\Client');
|
||||
$client->method('request')->withAnyParameters()->willReturn($response->reveal());
|
||||
|
|
Loading…
Reference in New Issue