From 39cdb0b3a8e724c722b899ec4840ae8a7cbc14e4 Mon Sep 17 00:00:00 2001 From: Charles Severance Date: Sat, 13 Aug 2016 20:43:48 -0400 Subject: [PATCH] Adjust the unit tests. --- unit3/testinp/trynum.inp | 1 + unit3/testout/tryexcept.txt | 2 ++ unit3/testout/trynum.txt | 1 + unit3/unit.py | 2 ++ 4 files changed, 6 insertions(+) create mode 100644 unit3/testinp/trynum.inp create mode 100644 unit3/testout/tryexcept.txt create mode 100644 unit3/testout/trynum.txt diff --git a/unit3/testinp/trynum.inp b/unit3/testinp/trynum.inp new file mode 100644 index 000000000..d81cc0710 --- /dev/null +++ b/unit3/testinp/trynum.inp @@ -0,0 +1 @@ +42 diff --git a/unit3/testout/tryexcept.txt b/unit3/testout/tryexcept.txt new file mode 100644 index 000000000..6a4db5b7c --- /dev/null +++ b/unit3/testout/tryexcept.txt @@ -0,0 +1,2 @@ +First -1 +Second 123 diff --git a/unit3/testout/trynum.txt b/unit3/testout/trynum.txt new file mode 100644 index 000000000..4a853ecd8 --- /dev/null +++ b/unit3/testout/trynum.txt @@ -0,0 +1 @@ +Enter a number:Nice work diff --git a/unit3/unit.py b/unit3/unit.py index a27f1a28b..478a3a0ef 100644 --- a/unit3/unit.py +++ b/unit3/unit.py @@ -20,6 +20,7 @@ ] toskip = [ + 'notry.py', # will always exception 'unit.py', # avoid infinite loops 'wikigrade.py', # talks to ctools - too complex 'argfile.py', # argument passing - no need to test @@ -92,3 +93,4 @@ diff = True if diff or fail >= 1 : sys.exit(1) +