提交 b6e4be83 编写于 作者: Q qqeasonchen

fix unit test

上级 4fa263f7
...@@ -398,13 +398,13 @@ public class DefaultMQProducerTest { ...@@ -398,13 +398,13 @@ public class DefaultMQProducerTest {
try { try {
producer.request(message, requestCallback, 3 * 1000L); producer.request(message, requestCallback, 3 * 1000L);
failBecauseExceptionWasNotThrown(RemotingSendRequestException.class); failBecauseExceptionWasNotThrown(Exception.class);
} catch (RemotingSendRequestException e) { } catch (Exception e) {
ConcurrentHashMap<String, RequestResponseFuture> responseMap = RequestFutureTable.getRequestFutureTable(); ConcurrentHashMap<String, RequestResponseFuture> responseMap = RequestFutureTable.getRequestFutureTable();
assertThat(responseMap).isNotNull(); assertThat(responseMap).isNotNull();
for (Map.Entry<String, RequestResponseFuture> entry : responseMap.entrySet()) { for (Map.Entry<String, RequestResponseFuture> entry : responseMap.entrySet()) {
RequestResponseFuture future = entry.getValue(); RequestResponseFuture future = entry.getValue();
future.getRequestCallback().onException(new Throwable()); future.getRequestCallback().onException(e);
} }
} }
countDownLatch.await(3000L, TimeUnit.MILLISECONDS); countDownLatch.await(3000L, TimeUnit.MILLISECONDS);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册