diff --git a/tests/integration/api/CreatePollTest.php b/tests/integration/api/CreatePollTest.php index df862df4..0ae4a521 100644 --- a/tests/integration/api/CreatePollTest.php +++ b/tests/integration/api/CreatePollTest.php @@ -257,6 +257,13 @@ public function authorized_user_can_create_post_poll_on_api(int $userId) $attributes = $data['attributes']; $this->assertEquals('Add a poll to an existing post', $attributes['question']); + + $pollId = $data['id']; + $this->assertNotNull($pollId); + + $poll = Poll::find($pollId); + $this->assertNotNull($poll); + $this->assertEquals(1, $poll->post_id); } /**