Parse into nested arguments

This commit is contained in:
Nathan Adams
2014-09-18 16:36:36 +02:00
parent a32243b704
commit 8d164e4b66
8 changed files with 97 additions and 17 deletions
@@ -24,4 +24,16 @@ public class ArgumentCommandNodeTest {
public void testParseInvalid() throws Exception {
node.parse("bar");
}
@Test
public void testParseChild() throws Exception {
node.addChild(argument("bar", integer()).build());
node.parse("123 123");
}
@Test(expected = IllegalCommandArgumentException.class)
public void testParseNoChildren() throws Exception {
node.parse("123 123");
}
}