Fixed tests for PHPUnit 5.7

This commit is contained in:
Dmitry Khomutov 2017-01-09 23:23:29 +07:00
commit 4d380a4aa4
8 changed files with 46 additions and 61 deletions

View file

@ -33,7 +33,7 @@ class ProjectServiceTest extends \PHPUnit_Framework_TestCase
public function setUp()
{
$this->mockProjectStore = $this->getMock('PHPCensor\Store\ProjectStore');
$this->mockProjectStore = $this->getMockBuilder('PHPCensor\Store\ProjectStore')->getMock();
$this->mockProjectStore->expects($this->any())
->method('save')
->will($this->returnArgument(0));
@ -115,7 +115,7 @@ class ProjectServiceTest extends \PHPUnit_Framework_TestCase
public function testExecute_DeleteProject()
{
$store = $this->getMock('PHPCensor\Store\ProjectStore');
$store = $this->getMockBuilder('PHPCensor\Store\ProjectStore')->getMock();
$store->expects($this->once())
->method('delete')
->will($this->returnValue(true));