diff options
| author | 2020-04-27 16:03:12 +0200 | |
|---|---|---|
| committer | 2020-04-27 16:03:12 +0200 | |
| commit | d21e5962be961a267cef6ffef4f7d4aaf1114a08 (patch) | |
| tree | de7c20032ed9d735ebdcd7975b9cb5f8ba3bc5c3 /tests/test_helpers.py | |
| parent | Add mock for discord.DMChannels (diff) | |
Add DMChannel tests for in_whitelist decorator
The `in_whitelist` decorator should not fail when a decorated command was called in a DMChannel; it should simply conclude that the user is not allowed to use the command. I've added a test case that uses a DMChannel context with User, not Member, objects.
In addition, I've opted to display a test case description in the `subTest`: Simply printing the actual arguments and context is messy and does not actually show you the information you'd like. This description is enough to figure out which test is failing and what the gist of the test is.
Diffstat (limited to 'tests/test_helpers.py')
0 files changed, 0 insertions, 0 deletions