SchedulerActor { public void addEntry(final AddEntryQueryMessage message) throws ResolutionException, ReadValueException { IOC.resolve(Keys.getOrAdd("new scheduler entry"), message.getEntryArguments(), service.getEntryStorage()); } SchedulerActor(final IObject args); void addEntry(final AddEntryQueryMessage message); void addEntryWithSettingId(final SetEntryIdMessage message); void addEntryList(final AddEntryQueryListMessage message); void listEntries(final ListEntriesQueryMessage message); void deleteEntry(final DeleteEntryQueryMessage message); void start(final StartStopMessage message); void stop(final StartStopMessage message); void configure(final ConfigureQueryMessage message);  }
@Test public void Should_createNewEntry() throws Exception { SchedulerActor actor = new SchedulerActor(args); actor.addEntry(addEntryQueryMessage); verify(newEntryStrategy).resolve(same(addEntryQueryMessage.getEntryArguments()), same(storage)); }