aboutsummaryrefslogtreecommitdiff
path: root/test.py
diff options
context:
space:
mode:
Diffstat (limited to 'test.py')
-rwxr-xr-xtest.py18
1 files changed, 17 insertions, 1 deletions
diff --git a/test.py b/test.py
index 86ca3db..3f74559 100755
--- a/test.py
+++ b/test.py
@@ -406,7 +406,7 @@ alice:
self.assertEqual(res.stdout, msg)
-class TestCarsAddCmd(unittest.TestCase):
+class TestCarsAdd(unittest.TestCase):
def setUp(self):
reset_state("test/state.json_3users")
@@ -471,6 +471,22 @@ foo:
self.assertEqual(res.stdout, o)
+class TestCarsRemove(unittest.TestCase):
+ def setUp(self):
+ reset_state("test/state.json_2cars")
+
+ def test_schieb_car(self):
+ i = "!cars remove foo"
+ res = run_bot(self, num[alice], i)
+ o = 'removed "foo" from the available cars'
+ self.assertEqual(res.stdout, o)
+
+ i = "!sum foo"
+ res = run_bot(self, num[alice], i)
+ o = 'ERROR: name "foo" not registered'
+ self.assertEqual(res.stdout, o)
+
+
class TestCarPayCmd(unittest.TestCase):
def setUp(self):
reset_state("test/state.json_2cars")