Refactored build type 'Pull request' logic.

This commit is contained in:
Dmitry Khomutov 2018-02-23 17:40:56 +07:00
commit 429405809e
No known key found for this signature in database
GPG key ID: EC19426474B37AAC
12 changed files with 143 additions and 80 deletions

View file

@ -3,7 +3,6 @@
namespace Tests\PHPCensor\Service;
use PHPCensor\Model\Build;
use PHPCensor\Model\Project;
use PHPCensor\Service\BuildService;
/**
@ -32,12 +31,14 @@ class BuildServiceTest extends \PHPUnit\Framework\TestCase
public function setUp()
{
$this->mockBuildStore = $this->getMockBuilder('PHPCensor\Store\BuildStore')->getMock();
$this->mockBuildStore->expects($this->any())
->method('save')
->will($this->returnArgument(0));
$this->mockBuildStore
->expects($this->any())
->method('save')
->will($this->returnArgument(0));
$this->mockEnvironmentStore = $this->getMockBuilder('PHPCensor\Store\EnvironmentStore')->getMock();
$this->mockEnvironmentStore->expects($this->any())
$this->mockEnvironmentStore
->expects($this->any())
->method('getByProjectId')
->will($this->returnValue(['items' => [], 'count' => 0]));