Skip to content

Commit d006101

Browse files
committed
fixes
1 parent faf9bd7 commit d006101

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

tests/Subscriber/NeedsReviewNewPRSubscriberTest.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ public function testOnPullRequestOpen()
5656

5757
public function testOnPullRequestOpenWIP()
5858
{
59-
$this->statusApi->expects($this->never())
59+
$this->statusApi->expects($this->once())
6060
->method('setIssueStatus')
61-
->with(1234, Status::NEEDS_REVIEW);
61+
->with(1234, Status::NEEDS_WORK);
6262

6363
$event = new GitHubEvent([
6464
'action' => 'opened',
@@ -68,7 +68,9 @@ public function testOnPullRequestOpenWIP()
6868
$this->dispatcher->dispatch($event, GitHubEvents::PULL_REQUEST);
6969

7070
$responseData = $event->getResponseData();
71-
$this->assertEmpty($responseData);
71+
$this->assertCount(2, $responseData);
72+
$this->assertSame(1234, $responseData['pull_request']);
73+
$this->assertSame(Status::NEEDS_WORK, $responseData['status_change']);
7274
}
7375

7476
public function testOnPullRequestNotOpen()

0 commit comments

Comments
 (0)