### Question:
DefaultEventManager implements EventManager { @Override public void registerListener(@NotNull Object listener) { for (Method declaredMethod : listener.getClass().getDeclaredMethods()) { Listener annotation = declaredMethod.getAnnotation(Listener.class); if (annotation == null) { continue; } Class<?>[] parameters = declaredMethod.getParameterTypes(); if (parameters.length != 1) { System.err.println("Unable to register listener method " + declaredMethod.getName() + "@" + listener.getClass().getName() + " because method has more or less than one parameter"); continue; } if (!Event.class.isAssignableFrom(parameters[0])) { System.err.println("Unable to register listener method " + declaredMethod.getName() + "@" + listener.getClass().getName() + " because parameter type " + parameters[0].getName() + " is not assignable from " + Event.class.getName()); continue; } ListenerContainer container = new DefaultListenerContainer(parameters[0], listener, declaredMethod, annotation.priority()); this.registeredListeners.add(container); } }  @Nullable @Override T callEvent(@NotNull Class<? extends T> event); @NotNull @Override T callEvent(@NotNull T event); @NotNull @Override Task<T> callEventAsync(@NotNull Class<? extends T> event); @NotNull @Override Task<T> callEventAsync(@NotNull T event); @Override void registerListener(@NotNull Object listener); @Override void registerListener(@NotNull Class<?> listener); @Override void unregisterListener(@NotNull Object listener); @Override void unregisterAll(); @NotNull @Override @UnmodifiableView List<ListenerContainer> getListeners();  }### Answer:
@Test @Order(1) void testRegisterListener() { this.eventManager.registerListener(TestListenerOne.class); Assertions.assertEquals(1, this.eventManager.getListeners().size()); this.eventManager.registerListener(TestListenerTwo.class); Assertions.assertEquals(1, this.eventManager.getListeners().size()); this.eventManager.registerListener(new TestListenerTwo(null)); Assertions.assertEquals(2, this.eventManager.getListeners().size()); }