public int size() { return events.size(); }
public int size() { return events.size(); }
@Test public void testFinishedStringImmutableMap() { activeEvents.active("hello", new BaseEventInfo()); activeEvents.finished("hello", ImmutableMap.of("hello", "world")); assertThat(activeEvents.events(), is(1)); assertThat(activeEvents.size(), is(0)); assertThat(activeEvents.toString(), containsString("world")); }
@Test public void testFinishedString() { activeEvents.active("hello", new BaseEventInfo()); activeEvents.finished("hello"); assertThat(activeEvents.events(), is(1)); assertThat(activeEvents.size(), is(0)); }
@Test public void testTwoEvents() { activeEvents.active("hello", new BaseEventInfo()); activeEvents.active("hello2", new BaseEventInfo()); assertThat(activeEvents.events(), is(2)); assertThat(activeEvents.size(), is(2)); }
@Test public void testTwoIdenticalEvents() { activeEvents.active("hello", new BaseEventInfo()); activeEvents.active("hello", new BaseEventInfo()); assertThat(activeEvents.events(), is(2)); assertThat(activeEvents.size(), is(1)); }
public int size() { return events.size(); }
public int size() { return events.size(); }