diff options
author | Olivier Gayot <olivier.gayot@sigexec.com> | 2020-09-13 00:27:55 +0200 |
---|---|---|
committer | Olivier Gayot <olivier.gayot@sigexec.com> | 2020-09-13 00:27:55 +0200 |
commit | ac77d76af2944c7f87a3e5e37ce654950926dfa9 (patch) | |
tree | c5176b2176c500b5278aef8d7c24950e1c7977ec /tests | |
parent | 1fc6905e87d9e7d25fde60a67f2d5e575123c6ea (diff) |
Add test for play_card without card ID specified
Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_swiftstory.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_swiftstory.py b/tests/test_swiftstory.py index 51dc837..d340613 100644 --- a/tests/test_swiftstory.py +++ b/tests/test_swiftstory.py @@ -40,3 +40,10 @@ class TestSwiftStory(unittest.TestCase): error("invalid command"), SwiftStory.message_received_handler(client=None, message='{}') ) + + def test_play_card_not_specified(self): + payload = '{"op": "play_white_card"}' + self.assertEqual( + error("field `card_id' is required"), + SwiftStory.message_received_handler(client=None, message=payload) + ) |