Skip to content

Commit

Permalink
added sleep for flaky tests
Browse files Browse the repository at this point in the history
Signed-off-by: Riya Saxena <[email protected]>
  • Loading branch information
riysaxen-amzn committed Feb 20, 2024
1 parent d4f1675 commit 0d3f7e4
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,7 @@ class SecureMonitorRestApiIT : AlertingRestTestCase() {
)
)
val createResponse = userClient?.makeRequest("POST", ALERTING_BASE_URI, emptyMap(), monitor.toHttpEntity())
Thread.sleep(30000)
assertEquals("Create monitor failed", RestStatus.CREATED, createResponse?.restStatus())
fail("Expected 403 Method FORBIDDEN response")
} catch (e: ResponseException) {
Expand Down Expand Up @@ -1314,6 +1315,7 @@ class SecureMonitorRestApiIT : AlertingRestTestCase() {

try {
val response = executeMonitor(userClient as RestClient, modifiedMonitor, params = DRYRUN_MONITOR)
Thread.sleep(20000)
val output = entityAsMap(response)
val inputResults = output.stringMap("input_results")
assertTrue("Missing monitor error message", (inputResults?.get("error") as String).isNotEmpty())
Expand Down

0 comments on commit 0d3f7e4

Please sign in to comment.