Example #1
0
 function it_returns_true_because_the_transition_is_in_use_by_any_issue(WorkflowInterface $workflow, StatusInterface $status, ProjectInterface $project, IssueInterface $issue, StatusTransitionInterface $transition2)
 {
     $this->getWorkflow()->shouldReturn($workflow);
     $workflow->getProjects()->shouldBeCalled()->willReturn([$project]);
     $project->getIssues()->shouldBeCalled()->willReturn([$issue]);
     $issue->getStatus()->shouldBeCalled()->willReturn($status);
     $status->getTransitions()->shouldBeCalled()->willReturn([$transition2]);
     $transition2->getId()->shouldBeCalled()->willReturn(null);
     $this->getId()->shouldReturn(null);
     $this->isInUse()->shouldReturn(true);
 }