aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJuan J. Martinez <jjm@usebox.net>2022-09-06 22:53:08 +0100
committerJuan J. Martinez <jjm@usebox.net>2022-09-06 22:53:08 +0100
commitcd9bd7decd25301a6da01fd97feed1cc33cfabbf (patch)
tree2b439efc7e4be565d0fde0838e34c87c5d90e8a6 /test
parentd08042be1e0ae158f124bb6848f5843a804a6544 (diff)
downloadmicro-lang-hs-cd9bd7decd25301a6da01fd97feed1cc33cfabbf.tar.gz
micro-lang-hs-cd9bd7decd25301a6da01fd97feed1cc33cfabbf.zip
Typecheck binary operator
Diffstat (limited to 'test')
-rw-r--r--test/Language.hs11
1 files changed, 10 insertions, 1 deletions
diff --git a/test/Language.hs b/test/Language.hs
index 0b7d6ac..2347b0e 100644
--- a/test/Language.hs
+++ b/test/Language.hs
@@ -379,6 +379,14 @@ testCaseE16 =
\a = false;"
E.TypeError
+testCaseE17 =
+ TestLabel "type mismatch in binary operator" $
+ TestCase $
+ expectError
+ "module main\n\
+ \1 + false;\n"
+ E.TypeError
+
language =
[ testCase2,
testCase3,
@@ -412,5 +420,6 @@ language =
testCaseE13,
testCaseE14,
testCaseE15,
- testCaseE16
+ testCaseE16,
+ testCaseE17
]