diff options
Diffstat (limited to 'test.py')
| -rwxr-xr-x | test.py | 18 |
1 files changed, 17 insertions, 1 deletions
@@ -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") |
