diff options
Diffstat (limited to 'chapter08/src/test/java')
| -rw-r--r-- | chapter08/src/test/java/com/seaofnodes/simple/Chapter08Test.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/chapter08/src/test/java/com/seaofnodes/simple/Chapter08Test.java b/chapter08/src/test/java/com/seaofnodes/simple/Chapter08Test.java index 16f7e324..057742c5 100644 --- a/chapter08/src/test/java/com/seaofnodes/simple/Chapter08Test.java +++ b/chapter08/src/test/java/com/seaofnodes/simple/Chapter08Test.java @@ -139,6 +139,13 @@ return arg; } @Test + public void testChapter8Regress2() { + Parser parser = new Parser("if(1) return 0; else while(arg>--arg) arg=arg+1; return 0;"); + StopNode stop = parser.parse(true); + assertEquals("Stop[ return 0; return 0; ]", stop.toString()); + } + + @Test public void testChapter8BreakOutsideLoop() { try { new Parser(""" |
