aboutsummaryrefslogtreecommitdiff
path: root/challenge-099/tyler-wardhaugh/python/test_ch1.py
diff options
context:
space:
mode:
Diffstat (limited to 'challenge-099/tyler-wardhaugh/python/test_ch1.py')
-rwxr-xr-xchallenge-099/tyler-wardhaugh/python/test_ch1.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/challenge-099/tyler-wardhaugh/python/test_ch1.py b/challenge-099/tyler-wardhaugh/python/test_ch1.py
new file mode 100755
index 0000000000..94e18be7b3
--- /dev/null
+++ b/challenge-099/tyler-wardhaugh/python/test_ch1.py
@@ -0,0 +1,17 @@
+#!/usr/bin/env python3
+
+import unittest
+from ch1 import pattern_match
+
+class TestTask1(unittest.TestCase):
+
+
+ def test_example_cases(self):
+ self.assertTrue(pattern_match("abcde", "a*e"))
+ self.assertFalse(pattern_match("abcde", "a*d"))
+ self.assertFalse(pattern_match("abcde", "?b*d"))
+ self.assertTrue(pattern_match("abcde", "a*c?e"))
+
+
+if __name__ == '__main__':
+ unittest.main()