Skip to content

Commit

Permalink
Update PublisherImplTest.java
Browse files Browse the repository at this point in the history
  • Loading branch information
hannahrogers-google authored Jan 12, 2024
1 parent 0c71e42 commit 067706e
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -524,14 +524,10 @@ public void testResumePublish() throws Exception {
.setEnableMessageOrdering(true)
.build();

ApiFuture<String> future1 = sendTestMessageWithOrderingKey(publisher, "m1", "orderA");
ApiFuture<String> future2 = sendTestMessageWithOrderingKey(publisher, "m2", "orderA");

assertFalse(future1.isDone());
assertFalse(future2.isDone());

// This exception should stop future publishing to the same key
testPublisherServiceImpl.addPublishError(new StatusException(Status.INVALID_ARGUMENT));
ApiFuture<String> future1 = sendTestMessageWithOrderingKey(publisher, "m1", "orderA");
ApiFuture<String> future2 = sendTestMessageWithOrderingKey(publisher, "m2", "orderA");

try {
future1.get();
Expand Down

0 comments on commit 067706e

Please sign in to comment.