aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorGravatar Leon Sandøy <[email protected]>2020-05-27 07:32:16 +0200
committerGravatar Leon Sandøy <[email protected]>2020-05-27 07:32:16 +0200
commitd9190d997538f49c0a1b53d63a15bada3c89297f (patch)
treee1a2db4240f97ed7c183b3fc7e1f718e313bafc7 /tests
parentMerge pull request #866 from python-discord/restricted_tags (diff)
Refactor the in_whitelist deco to a check.
We're moving the actual predicate into the `utils.checks` folder, just like we're doing with most of the other decorators. This is to allow us the flexibility to use it as a pure check, not only as a decorator. This commit doesn't actually change any functionality, just moves it around.
Diffstat (limited to 'tests')
-rw-r--r--tests/bot/test_decorators.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/bot/test_decorators.py b/tests/bot/test_decorators.py
index a17dd3e16..3d450caa0 100644
--- a/tests/bot/test_decorators.py
+++ b/tests/bot/test_decorators.py
@@ -3,10 +3,10 @@ import unittest
import unittest.mock
from bot import constants
-from bot.decorators import InWhitelistCheckFailure, in_whitelist
+from bot.decorators import in_whitelist
+from bot.utils.checks import InWhitelistCheckFailure
from tests import helpers
-
InWhitelistTestCase = collections.namedtuple("WhitelistedContextTestCase", ("kwargs", "ctx", "description"))