Skip to content

Commit

Permalink
fix unit test failures
Browse files Browse the repository at this point in the history
  • Loading branch information
nobodyiam committed Jan 30, 2025
1 parent 7560f5b commit ac92ca0
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import com.ctrip.framework.apollo.monitor.internal.listener.ApolloClientMonitorEventListener;
import com.ctrip.framework.apollo.monitor.internal.ApolloClientMonitorContext;
import com.ctrip.framework.apollo.util.ConfigUtil;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;

Expand All @@ -47,6 +48,11 @@ public void setUp() {
ApolloClientMonitorEventPublisher.reset();
}

@After
public void tearDown() throws Exception {
MockInjector.reset();
}

@Test
public void testPublish_WhenClientMonitorEnabled_CollectorSupportsEvent() {
when(mockConfigUtil.isClientMonitorEnabled()).thenReturn(true);
Expand Down

0 comments on commit ac92ca0

Please sign in to comment.