Skip to content

Commit

Permalink
increasing wait for events to popup
Browse files Browse the repository at this point in the history
  • Loading branch information
salaboy committed Feb 4, 2025
1 parent 100d037 commit 265c708
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ void testMessageConsumer() throws InterruptedException, IOException {


await()
.atMost(Duration.ofSeconds(5))
.atMost(Duration.ofSeconds(10))
.until(subscriberRestController.getAllEvents()::size, equalTo(1));


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,9 @@ void testOrdersEndpointAndMessaging() throws InterruptedException, IOException {
.post("/orders")
.then()
.statusCode(200);



await()
.atMost(Duration.ofSeconds(5))
.atMost(Duration.ofSeconds(10))
.until(controller.getAllEvents()::size, equalTo(1));

given()
Expand Down Expand Up @@ -111,9 +110,10 @@ void testCustomersWorkflows() throws InterruptedException, IOException {
.statusCode(200);


assertEquals(1, customerStore.getCustomers().size());
await()
.atMost(Duration.ofSeconds(10))
.until(customerStore.getCustomers()::size, equalTo(1));
Customer customer = customerStore.getCustomer("salaboy");

assertEquals(true, customer.isInCustomerDB());
String workflowId = customer.getWorkflowId();
given()
Expand All @@ -127,7 +127,7 @@ void testCustomersWorkflows() throws InterruptedException, IOException {
assertEquals(1, customerStore.getCustomers().size());

await()
.atMost(Duration.ofSeconds(5))
.atMost(Duration.ofSeconds(10))
.until(customerStore.getCustomer("salaboy")::isFollowUp, equalTo(true));

}
Expand Down

0 comments on commit 265c708

Please sign in to comment.