Skip to content

Commit

Permalink
Fix Tests
Browse files Browse the repository at this point in the history
  • Loading branch information
johann8384 committed Sep 21, 2016
1 parent dc19d8e commit 83b067e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 1 addition & 3 deletions src/tsd/RpcManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -273,9 +273,7 @@ private void initializeBuiltinRpcs(final String mode,
final DropCachesRpc dropcaches = new DropCachesRpc();
final ListAggregators aggregators = new ListAggregators();
final SuggestRpc suggest_rpc = new SuggestRpc();
if (enableAnnotations) {
final AnnotationRpc annotation_rpc = new AnnotationRpc();
}
final AnnotationRpc annotation_rpc = new AnnotationRpc();
final Version version = new Version();

telnet.put("stats", stats);
Expand Down
8 changes: 7 additions & 1 deletion test/tsd/TestRpcManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ public void before() {
.thenReturn("true");
when(config.getString("tsd.core.enable_ui"))
.thenReturn("true");
when(config.getString("tsd.core.enable_annotations"))
.thenReturn("true");
when(config.getString("tsd.no_diediedie"))
.thenReturn("false");
TSDB tsdb = mock(TSDB.class);
Expand All @@ -75,8 +77,10 @@ public void loadHttpRpcPlugins() throws Exception {
.thenReturn("true");
when(config.getString("tsd.core.enable_ui"))
.thenReturn("true");
when(config.getString("tsd.core.enable_annotations"))
.thenReturn("true");
when(config.getString("tsd.no_diediedie"))
.thenReturn("false");
.thenReturn("false");

TSDB tsdb = mock(TSDB.class);
when(tsdb.getConfig()).thenReturn(config);
Expand Down Expand Up @@ -105,6 +109,8 @@ public void loadRpcPlugin() throws Exception {
.thenReturn("true");
when(config.getString("tsd.core.enable_ui"))
.thenReturn("true");
when(config.getString("tsd.core.enable_annotations"))
.thenReturn("true");
when(config.getString("tsd.no_diediedie"))
.thenReturn("false");

Expand Down

0 comments on commit 83b067e

Please # to comment.