EndElementProcessor implements XmlEventProcessor { @Override public ImmutableList<XMLEvent> process(String id, XMLEvent event) { Preconditions.checkNotNull(event); return ImmutableList.of(event); }  @Override boolean accepts(XMLEvent event); @Override ImmutableList<XMLEvent> process(String id, XMLEvent event);  }
@Test public void testProcess() { test.given(eventIsEndElement("rect")) .when(process()) .then(eventProcessed()); }