Class MockEventPublisher

  • All Implemented Interfaces:
    com.atlassian.event.api.EventListenerRegistrar, com.atlassian.event.api.EventPublisher

    public class MockEventPublisher
    extends Object
    implements com.atlassian.event.api.EventPublisher
    • Constructor Detail

      • MockEventPublisher

        public MockEventPublisher()
    • Method Detail

      • publish

        public void publish​(Object o)
        Specified by:
        publish in interface com.atlassian.event.api.EventPublisher
      • register

        public void register​(Object o)
        Specified by:
        register in interface com.atlassian.event.api.EventListenerRegistrar
      • unregister

        public void unregister​(Object o)
        Specified by:
        unregister in interface com.atlassian.event.api.EventListenerRegistrar
      • unregisterAll

        public void unregisterAll()
        Specified by:
        unregisterAll in interface com.atlassian.event.api.EventListenerRegistrar
      • publishedEvents

        public List<Object> publishedEvents()
      • publishedEventsOfType

        public <T> Stream<T> publishedEventsOfType​(Class<T> eventClass)
      • countPublishedEvents

        public <T> long countPublishedEvents​(Class<T> eventClass,
                                             Predicate<T> eventsPredicate)
      • reset

        public void reset()