Ejemplo n.º 1
0
 public void assertEnd(Class expectedClass, int expectedIndex) {
   Event.Stop event = (Event.Stop) parser.next();
   assertEquals(expectedClass, event.getClass());
   assertEquals(expectedIndex, event.getIndex());
 }
Ejemplo n.º 2
0
 public void assertArgument(String name, String... values) {
   Event.Argument event = (Event.Argument) parser.next();
   assertEquals(name, event.getParameter().getName());
   assertEquals(Arrays.asList(values), event.getStrings());
 }
Ejemplo n.º 3
0
 public void assertMethod(String name) {
   Event.Subordinate event = (Event.Subordinate) parser.next();
   assertEquals(name, event.getDescriptor().getName());
 }
Ejemplo n.º 4
0
 public void assertOption(String name, String... values) {
   Event.Option event = (Event.Option) parser.next();
   assertTrue(event.getParameter().getNames().contains(name));
   assertEquals(Arrays.asList(values), event.getStrings());
 }
Ejemplo n.º 5
0
 public void assertSeparator() {
   Event event = parser.next();
   assertTrue("was expecting a separator instead of " + event, event instanceof Event.Separator);
 }