summaryrefslogtreecommitdiffhomepage
path: root/systemtest
diff options
context:
space:
mode:
authorRoland Reichwein <mail@reichwein.it>2020-11-22 22:14:23 +0100
committerRoland Reichwein <mail@reichwein.it>2020-11-22 22:14:23 +0100
commitff69e8cab318101843cd8b49a0cb04df9763e10f (patch)
tree58778d0ba28264880df8bdf6bfe45766939c3af9 /systemtest
parentad3fd947005400c90f41baa4416a27d94b1bc157 (diff)
Generalize Add / Mul, Integer promotion, tests
Diffstat (limited to 'systemtest')
-rw-r--r--systemtest/mcc-execute.tests/exitcodes.exp3
-rw-r--r--systemtest/mcc-execute.tests/test-parentheses-left.cpp1
-rw-r--r--systemtest/mcc-execute.tests/test-parentheses-right.cpp1
-rw-r--r--systemtest/mcc-execute.tests/test-parentheses.cpp1
4 files changed, 6 insertions, 0 deletions
diff --git a/systemtest/mcc-execute.tests/exitcodes.exp b/systemtest/mcc-execute.tests/exitcodes.exp
index 0480be8..dc4d377 100644
--- a/systemtest/mcc-execute.tests/exitcodes.exp
+++ b/systemtest/mcc-execute.tests/exitcodes.exp
@@ -5,4 +5,7 @@ runtest_exit_code "Addition" "systemtest/mcc-execute.tests/test-addition" 3
runtest_exit_code "Multiplication" "systemtest/mcc-execute.tests/test-multiplication" 6
runtest_exit_code "Division" "systemtest/mcc-execute.tests/test-division" 2
runtest_exit_code "Modulo" "systemtest/mcc-execute.tests/test-modulo" 1
+runtest_exit_code "Parentheses Tree" "systemtest/mcc-execute.tests/test-parentheses" 36
+runtest_exit_code "Parentheses Left" "systemtest/mcc-execute.tests/test-parentheses-left" 36
+runtest_exit_code "Parentheses Right" "systemtest/mcc-execute.tests/test-parentheses-right" 36
diff --git a/systemtest/mcc-execute.tests/test-parentheses-left.cpp b/systemtest/mcc-execute.tests/test-parentheses-left.cpp
new file mode 100644
index 0000000..2ebc713
--- /dev/null
+++ b/systemtest/mcc-execute.tests/test-parentheses-left.cpp
@@ -0,0 +1 @@
+int main() { return (((((((1 + 2) + 3) + 4) + 5) + 6) + 7) + 8); }
diff --git a/systemtest/mcc-execute.tests/test-parentheses-right.cpp b/systemtest/mcc-execute.tests/test-parentheses-right.cpp
new file mode 100644
index 0000000..662af95
--- /dev/null
+++ b/systemtest/mcc-execute.tests/test-parentheses-right.cpp
@@ -0,0 +1 @@
+int main() { return (1 + (2 + (3 + (4 + (5 + (6 + (7 + 8))))))); }
diff --git a/systemtest/mcc-execute.tests/test-parentheses.cpp b/systemtest/mcc-execute.tests/test-parentheses.cpp
new file mode 100644
index 0000000..fca52e9
--- /dev/null
+++ b/systemtest/mcc-execute.tests/test-parentheses.cpp
@@ -0,0 +1 @@
+int main() { return ((1 + 2) + (3 + 4)) + ((5 + 6) + (7 + 8)); }