Skip to content

Commit

Permalink
(test) Adding test case for empty results body
Browse files Browse the repository at this point in the history
  • Loading branch information
craigatk committed Sep 21, 2020
1 parent ebf5836 commit 19a1459
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,13 @@ class SaveGroupedResultsErrorApplicationTest : ApplicationTestCase() {
}
}
}

@Test
fun `when empty results body should respond with 400`() {
withTestApplication(::createTestApplication) {
handleRequest(HttpMethod.Post, "/groupedResults").apply {
expectThat(response.status()).isEqualTo(HttpStatusCode.BadRequest)
}
}
}
}

0 comments on commit 19a1459

Please sign in to comment.