diff options
| author | 2020-06-24 15:03:38 +0300 | |
|---|---|---|
| committer | 2020-06-24 15:03:38 +0300 | |
| commit | 024633a470d86d84189c714d194e750507f47d47 (patch) | |
| tree | 75cd292201b677e5412f23e9e03025771950fae9 /tests | |
| parent | Mod Utils Tests: Move some test cases to `namedtuple` (diff) | |
Mod Utils Tests: Change `True` assert to `In` assert for message check
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/bot/cogs/moderation/test_utils.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/bot/cogs/moderation/test_utils.py b/tests/bot/cogs/moderation/test_utils.py index e54c0d240..aaa0861e5 100644 --- a/tests/bot/cogs/moderation/test_utils.py +++ b/tests/bot/cogs/moderation/test_utils.py @@ -59,8 +59,9 @@ class ModerationUtilsTests(unittest.IsolatedAsyncioTestCase): if case.send_msg and case.get_return_value: self.ctx.send.assert_awaited_once() - self.assertTrue(case.infraction_nr in self.ctx.send.call_args[0][0]) - self.assertTrue("ban" in self.ctx.send.call_args[0][0]) + sent_message = self.ctx.send.call_args[0][0] + self.assertIn(case.infraction_nr, sent_message) + self.assertIn("ban", sent_message) else: self.ctx.send.assert_not_awaited() |