diff options
author | 2020-07-22 16:54:53 -0700 | |
---|---|---|
committer | 2020-07-22 16:55:44 -0700 | |
commit | 8e3c05210f057ab76d135afbe12035847c9029f4 (patch) | |
tree | cdaed299efbc4b4e78d8c79df5a28e7329a7d238 | |
parent | Jam tests: assert equality of new category (diff) |
Jam tests: use the MAX_CHANNELS constant more
It's clearer to write MAX_CHANNELS - 2 than a literal 48.
-rw-r--r-- | tests/bot/cogs/test_jams.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/bot/cogs/test_jams.py b/tests/bot/cogs/test_jams.py index a76a8a051..b4ad8535f 100644 --- a/tests/bot/cogs/test_jams.py +++ b/tests/bot/cogs/test_jams.py @@ -72,7 +72,7 @@ class JamCreateTeamTests(unittest.IsolatedAsyncioTestCase): subtests = ( [], [get_mock_category(jams.MAX_CHANNELS - 1, jams.CATEGORY_NAME)], - [get_mock_category(48, "other")], + [get_mock_category(jams.MAX_CHANNELS - 2, "other")], ) for categories in subtests: @@ -91,11 +91,11 @@ class JamCreateTeamTests(unittest.IsolatedAsyncioTestCase): async def test_category_channel_exist(self): """Should not try to create category channel.""" - expected_category = get_mock_category(48, jams.CATEGORY_NAME) + expected_category = get_mock_category(jams.MAX_CHANNELS - 2, jams.CATEGORY_NAME) self.guild.categories = [ - get_mock_category(48, "other"), + get_mock_category(jams.MAX_CHANNELS - 2, "other"), expected_category, - get_mock_category(6, jams.CATEGORY_NAME), + get_mock_category(0, jams.CATEGORY_NAME), ] actual_category = await self.cog.get_category(self.guild) |