change perl program calls
[calc.git] / calc.c
diff --git a/calc.c b/calc.c
index cad608fe528f52bfcded3425a3c4bc5f5a595da3..08ff10c14308c34769a49fb69af5111c367033a9 100644 (file)
--- a/calc.c
+++ b/calc.c
@@ -372,7 +372,7 @@ int main (int argc, char *argv[])
 // test: echo -e 'si\t\t (pi / 2)' | calc.exe | grep -q '=> 1'
 // test: echo -e '\t\t' | calc.exe | grep -q 'print'
 // test: echo -e '1 + 1;\nans + 1' | calc.exe | grep -qv 2
-// test: echo -e 'mem (3)\nsto (4, pi)' | calc.exe | grep -q error
+// test: echo -e 'mem\nmem (3)\nsto (4, pi)' | calc.exe | grep -q "error out of bound"
 // test: echo -e 'sto (2, 3)\nmem (2)\ndisp' | calc.exe | grep -q 'storage: 0 3$'
 // test: echo -e 'disp' | calc.exe | grep -q "storage: 0 0 0 0 0 0 0 0 0 0"
 // test: echo -e 'sto (3, 10)\ndisp' | calc.exe | grep -q "storage: 0 0 10 0 0 0 0 0 0 0"
@@ -413,6 +413,6 @@ int main (int argc, char *argv[])
 // test: echo -e '{sto (1, 1), sto (2, 1), sto (10, 1), while (inc (10) < 15 - 1, {sto (3, rcl (1) + rcl (2)), sto (1, rcl (2)), print (sto (2, rcl (3)) / rcl (1))})};' | calc.exe | grep -q '=> 1.61803'
 
 // Factorial sequence
-// test: echo -e 'prog (1, cond (arg (1) > 1, arg (1) * call (1, arg (1) - 1), 1))\ncall (1, 10)' | ./calc.exe | grep -q '=> 3628800'
+// test: echo -e 'prog (1, cond (arg (1) > 1, arg (1) * call (1, arg (1) - 1), 1))\ncall (1, 10)' | calc.exe | grep -q '=> 3.6288e+06'
 
 /* vim: set ts=4 sw=4 et: */