@Test
public void testTagSeenEventAfterEnd_ShouldBeIgnored() throws Exception {

    Snapshot snapshot = new Snapshot(Instant.EPOCH);
    AddTagEvent addTagEvent = new AddTagEvent(Instant.EPOCH.plus(1, ChronoUnit.SECONDS), new TagId("DCBA"), 3);
    snapshot = addTagEvent.doApply(snapshot);
    StartEvent startEvent = new StartEvent(Instant.EPOCH.plus(2, ChronoUnit.SECONDS));
    snapshot = startEvent.doApply(snapshot);
    TagSeenEvent tagSeenEvent =
            new TagSeenEvent(Instant.EPOCH.plus(3, ChronoUnit.SECONDS), new TagId("DCBA"), 0, 0L);
    snapshot = tagSeenEvent.doApply(snapshot);
    EndEvent endEvent = new EndEvent(Instant.EPOCH.plus(50, ChronoUnit.SECONDS));
    snapshot = endEvent.doApply(snapshot);
    TagSeenEvent tagSeenEvent2 =
            new TagSeenEvent(Instant.EPOCH.plus(100, ChronoUnit.SECONDS), new TagId("DCBA"), 0, 1L);
    snapshot = tagSeenEvent2.doApply(snapshot);
    MatcherAssert.assertThat(snapshot.getTeamStates().getNbLapsForTeam(3), Matchers.equalTo(0));
}