Skip to content

Commit

Permalink
Fix phpstan
Browse files Browse the repository at this point in the history
  • Loading branch information
eiriksm committed Jul 28, 2023
1 parent a8f2e9a commit c32a725
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions test/integration/UpdateGitlabAssigneesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,22 @@
class UpdateGitlabAssigneesTest extends UpdateExistingWithAssigneesTest
{

/**
* @var FakeGitlab
*/
protected $myProvider;

public function setUp(): void
{
parent::setUp();
}

protected function getMockProvider()
{
if (!$this->mockProvider) {
$this->mockProvider = new FakeGitlab(new FakeGitlabClient());
if (!$this->myProvider instanceof FakeGitlab) {
$this->myProvider = new FakeGitlab(new FakeGitlabClient());
}
return $this->mockProvider;
return $this->myProvider;
}

protected function setDummyGithubProvider()
Expand All @@ -40,7 +45,7 @@ public function testPrUpdatedWhenConflict($exception_class)
$this->cosy->setProject($project);
$this->cosy->setUrl('https://gitlab.com/a/b');
$this->runtestExpectedOutput();
$calls = $this->mockProvider->getClient()->getCalls();
$calls = $this->myProvider->getClient()->getCalls();
foreach ($calls as $call) {
if ($call[0] !== 'MergeRequests' || $call[1] !== 'update') {
continue;
Expand Down

0 comments on commit c32a725

Please sign in to comment.