Skip to content

Commit

Permalink
[Tests] RichText RendererTest: Fixed mocks to align with PHPUnit 5.7 (e…
Browse files Browse the repository at this point in the history
…zsystems#2144)

* [Unit tests] RichText RendererTest: Mocked Core Repository to mock sudo

* [Unit tests] RichText RendererTest: Renamed getMock to createMock

getMock is deprecated
  • Loading branch information
alongosz authored and andrerom committed Nov 13, 2017
1 parent 9ad9ddd commit a62e5fc
Showing 1 changed file with 3 additions and 4 deletions.
Expand Up @@ -8,8 +8,7 @@
*/
namespace eZ\Publish\Core\MVC\Symfony\FieldType\Tests\RichText;


use eZ\Publish\API\Repository\Repository;
use eZ\Publish\Core\Repository\Repository;
use eZ\Publish\API\Repository\Values\Content\Location;
use eZ\Publish\API\Repository\Values\Content\Content;
use eZ\Publish\API\Repository\Values\Content\ContentInfo;
Expand Down Expand Up @@ -527,14 +526,14 @@ public function testRenderContentEmbedTrashed()
$parameters = array('parameters');
$isInline = true;

$contentInfoMock = $this->getMock(ContentInfo::class);
$contentInfoMock = $this->createMock(ContentInfo::class);
$contentInfoMock
->expects($this->once())
->method('__get')
->with('mainLocationId')
->willReturn(null);

$contentMock = $this->getMock(Content::class);
$contentMock = $this->createMock(Content::class);
$contentMock
->expects($this->once())
->method('__get')
Expand Down

0 comments on commit a62e5fc

Please sign in to comment.