  @Test public void trackFromAspectEvent() throws Throwable {

    class Foo {
      @TrackEvent("event_name") public void foo() {
      }
    }
    TrackEvent trackEvent = Foo.class.getMethod("foo").getAnnotation(TrackEvent.class);

    Map<String, Object> attributes = new HashMap<>();
    attributes.put("key", "value");

    tracklytics.onAspectEventTriggered(trackEvent, attributes);

    verify(eventSubscriber).onEventTracked(eventCaptor.capture());

    assertThat(eventCaptor.getValue().name).isEqualTo("event_name");
    assertThat(eventCaptor.getValue().attributes).containsExactly("key", "value");
  }