SchedulerStateResource { @Timed @GET public GetSchedulerStateResponse getState() { return new GetSchedulerStateResponse(toStringCollection(state.getPendingTaskIds()), toStringCollection( state.getStagingTaskIds()), toStringCollection(state.getActiveTaskIds()), toStringCollection(state.getKillableTaskIds())); } @Inject  SchedulerStateResource(final MyriadConfiguration cfg, final org.apache.myriad.state.SchedulerState state); @Timed @GET GetSchedulerStateResponse getState();  }
@Test public void test() throws Exception { GetSchedulerStateResponse response = resource.getState(); assertNotNull(response); assertEquals(1, response.getActiveTasks().size()); assertEquals(1, response.getPendingTasks().size()); assertEquals(1, response.getStagingTasks().size()); }