### Question:
LoginSuccessEventListener extends EventListener { @Override public boolean canHandle(Object event) { return event instanceof AuthenticationSuccessEvent; } LoginSuccessEventListener(EventService eventService,
			UsersRepository usersRepository); @Override boolean canHandle(Object event); @Override void handle(Object event);  }### Answer:
@Test public void testCanHandle_when_event_unmatch() { AuthenticationFailureBadCredentialsEvent event=mock(AuthenticationFailureBadCredentialsEvent.class); assertEquals(loginSuccessEventListener.canHandle(event),false); }
@Test public void testCanHandle_when_event_matches() { AuthenticationSuccessEvent event=mock(AuthenticationSuccessEvent.class); assertEquals(loginSuccessEventListener.canHandle(event),true); }