Skip to content

Commit

Permalink
Fix unit test (apache#6006)
Browse files Browse the repository at this point in the history
### Motivation

Since apache#5599 merged, it introduce some conflict code with master branch, maybe the reason is apache#5599 not rebase with master

### Verifying this change

This is a test change
  • Loading branch information
codelipenghui authored and jiazhai committed Jan 8, 2020
1 parent 8d200b6 commit 275854e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -946,9 +946,9 @@ public void testStuckTopicUnloading() throws Exception {
.get(mlFactory);
assertNotNull(ledgers.get(topicMlName));

org.apache.pulsar.broker.service.Producer prod = spy(topic.producers.values().get(0));
org.apache.pulsar.broker.service.Producer prod = (org.apache.pulsar.broker.service.Producer) spy(topic.producers.values().toArray()[0]);
topic.producers.clear();
topic.producers.add(prod);
topic.producers.put(prod.getProducerName(), prod);
CompletableFuture<Void> waitFuture = new CompletableFuture<Void>();
doReturn(waitFuture).when(prod).disconnect();
Set<NamespaceBundle> bundles = pulsar.getNamespaceService().getOwnedServiceUnits();
Expand Down

0 comments on commit 275854e

Please sign in to comment.