Skip to content

Commit

Permalink
[SCB-1804] fix random fail test case
Browse files Browse the repository at this point in the history
  • Loading branch information
liubao68 committed Mar 17, 2020
1 parent c4e16a1 commit 192e4ac
Showing 1 changed file with 13 additions and 1 deletion.
Expand Up @@ -147,7 +147,11 @@ public void doAppend(LoggingEvent event) {
}.getMockInstance();
rootLogger.addAppender(appender);

doRun(events);
try {
doRun(events);
} catch (Throwable e) {
e.printStackTrace();
}

rootLogger.removeAppender(appender);
}
Expand Down Expand Up @@ -175,6 +179,14 @@ void doRun(java.util.List<LoggingEvent> events) {

@Test
public void testRegisterSchemaException() {
new MockUp<RestClientUtil>() {
@Mock
void put(IpPort ipPort, String uri, RequestParam requestParam,
Handler<RestResponse> responseHandler) {
// do nothing to mock null response
}
};

InterruptedException e = new InterruptedException();
new MockUp<CountDownLatch>() {
@Mock
Expand Down

0 comments on commit 192e4ac

Please sign in to comment.