### Question:
TimerService { public synchronized void invoke( TimerName name ) { getTimers( name ).forEach( Timer::invoke ); } TimerService( JobScheduler scheduler, LogProvider logProvider ); synchronized Timer create( TimerName name, Group group, TimeoutHandler handler ); synchronized Collection<Timer> getTimers( TimerName name ); synchronized void invoke( TimerName name );  }### Answer:
@Test public void shouldInvokeTimersOnExplicitInvocation() throws Exception { timerService.invoke( TIMER_A ); verify( handlerA, times( 1 ) ).onTimeout( timerA ); verify( handlerB, never() ).onTimeout( any() ); reset( handlerA ); reset( handlerB ); timerService.invoke( TIMER_B ); verify( handlerA, never() ).onTimeout( any() ); verify( handlerB, times( 1 ) ).onTimeout( timerB ); }