summaryrefslogtreecommitdiff
path: root/chapter05/src/test
diff options
context:
space:
mode:
authorXmiliaH <45106915+XmiliaH@users.noreply.github.com>2023-11-01 12:27:00 +0100
committerDibyendu Majumdar <dibyendumajumdar@users.noreply.github.com>2023-11-01 18:56:50 +0000
commit906241d5257f99b9c7de2da5340f5a59c2fb688d (patch)
tree0795391a0d73df8a5f581effc6b874c59d498713 /chapter05/src/test
parent9441ef1c88c44761e2f1105d7b7a00178af4339c (diff)
downloadSimple-906241d5257f99b9c7de2da5340f5a59c2fb688d.tar.gz
Simple-906241d5257f99b9c7de2da5340f5a59c2fb688d.zip
Test expecting an excpetion is missing an fail (#29)
Diffstat (limited to 'chapter05/src/test')
-rw-r--r--chapter05/src/test/java/com/seaofnodes/simple/Chapter05Test.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/chapter05/src/test/java/com/seaofnodes/simple/Chapter05Test.java b/chapter05/src/test/java/com/seaofnodes/simple/Chapter05Test.java
index ab956e9f..5ac309f3 100644
--- a/chapter05/src/test/java/com/seaofnodes/simple/Chapter05Test.java
+++ b/chapter05/src/test/java/com/seaofnodes/simple/Chapter05Test.java
@@ -301,6 +301,7 @@ return c;
public void testSelfAssign() {
try {
new Parser("int a=a; return a;").parse();
+ fail();
} catch( RuntimeException e ) {
assertEquals("Undefined name 'a'",e.getMessage());
}