Skip to content

Commit

Permalink
fix test code
Browse files Browse the repository at this point in the history
  • Loading branch information
coderzc committed Sep 20, 2022
1 parent 728736f commit 582b076
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,6 @@ public void testAddMessageWithDeliverAtTimeAfterFullTickTimeWithStrict(DelayedDe
// Wait longer than the tick time plus the HashedWheelTimer's tick time to ensure that enough time has
// passed where it would have been triggered if the tick time was doing the triggering.
Thread.sleep(1000);
verify(dispatcher).getCursor();

// Not wait for the message delivery to get triggered.
Awaitility.await().atMost(10, TimeUnit.SECONDS)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public class MockManagedCursor implements ManagedCursor {

private final String name;

private Map<String, String> cursorProperties;
private final Map<String, String> cursorProperties;

public MockManagedCursor(String name) {
this.name = name;
Expand Down Expand Up @@ -76,6 +76,11 @@ public CompletableFuture<Void> putCursorProperty(String key, String value) {
return CompletableFuture.completedFuture(null);
}

@Override
public CompletableFuture<Void> setCursorProperties(Map<String, String> cursorProperties) {
return CompletableFuture.completedFuture(null);
}

public CompletableFuture<Void> removeCursorProperty(String key) {
cursorProperties.remove(key);
return CompletableFuture.completedFuture(null);
Expand Down

0 comments on commit 582b076

Please sign in to comment.