aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeLines
...
| | | | | | | * | | | | | | | Defer imports in extensions using __init__.pyGravatar MarkKoz2020-08-14-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since `pkgutil.walk_packages` imports packages it comes across, it's best to avoid potential side effects from imports.
| | | | | | | * | | | | | | | Extensions: support unqualified extension namesGravatar MarkKoz2020-08-14-3/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's convenient for users to type less to specify the exception they want. Only require a qualified name if an unqualified name is ambiguous (i.e. two modules in different subpackages have identical names).
| | | | | | | * | | | | | | | Extensions: refactor category grouping codeGravatar MarkKoz2020-08-14-3/+2
| | | | | | | | | | | | | | |
| | | | | | | * | | | | | | | Extensions: support nested groupings in list commandGravatar MarkKoz2020-08-14-6/+5
| | | | | | | | | | | | | | |
| | | | | | | * | | | | | | | Extensions: group by category in list commandGravatar MarkKoz2020-08-14-9/+29
| | | | | | | | | | | | | | |
| | | | | | | * | | | | | | | Extensions: adjust discovery to work with dir structureGravatar MarkKoz2020-08-14-8/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Discover extensions recursively and ignore any modules/packages whose names start with an underscore.
| | | | | | | * | | | | | | | Fix paths used to load extensionsGravatar MarkKoz2020-08-14-38/+55
| | | | | | | | | | | | | | |
| | | | | | | * | | | | | | | Fix ModLog importsGravatar MarkKoz2020-08-14-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bunch of modules still rely on importing the cog directly from the moderation package.
| | | | | | | * | | | | | | | Prefix names of non-extension modules with _Gravatar MarkKoz2020-08-14-87/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This naming scheme will make them easy to distinguish from extensions.
| | | | | | | * | | | | | | | Restructure tests and fix broken testsGravatar MarkKoz2020-08-14-37/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The cog tests structure should mirror the structure of the cogs folder. Fix some import/patch paths which broke due to the restructure.
| | | | | | | * | | | | | | | Move extensions into sub-directoriesGravatar MarkKoz2020-08-13-23/+23
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Apply recent changes of notify infraction to testGravatar ks1292020-09-20-3/+2
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Try to fix location from where post infraction test get IDGravatar ks1292020-09-20-2/+2
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove useless textwrap importGravatar ks1292020-09-20-1/+0
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove special shortening from reasonGravatar ks1292020-09-20-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Shorten infraction text when any other field than reason is too longGravatar ks1292020-09-13-0/+4
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Restore newlines for `notify_infraction` embed descriptionGravatar Karlis S2020-07-06-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Truncate reason instead full content to avoid removing newlines
| | | | | | | | * | | | | | | Remove unnecessary if statement from send_private_embed testGravatar ks1292020-06-25-2/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Reorder tests order to match with original fileGravatar ks1292020-06-24-65/+65
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove unnecessary `textwrap.dedent` in `notify_infraction`Gravatar ks1292020-06-24-6/+4
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Move infraction description template back to main file, apply it thereGravatar ks1292020-06-24-16/+18
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Fix test case key name in `test_notify_infraction`Gravatar ks1292020-06-24-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Add other parameters to `test_post_user` `not_user` mockGravatar ks1292020-06-24-5/+5
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove unnecessary `log.debug` assert in `test_post_user`Gravatar ks1292020-06-24-8/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Merge 2 if-else branches is `test_post_user`Gravatar ks1292020-06-24-5/+2
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Replace `True` test with `In` test on `test_post_user`Gravatar ks1292020-06-24-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Sync keys, variable names and kwargs in `test_post_user`Gravatar ks1292020-06-24-12/+12
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove case variable definitions in `test_notify_infraction`Gravatar ks1292020-06-24-10/+6
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils Tests: Remove unnecessary `user` from test nameGravatar ks1292020-06-24-1/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils Tests: Change `True` assert to `In` assert for message checkGravatar ks1292020-06-24-2/+3
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils Tests: Move some test cases to `namedtuple`Gravatar ks1292020-06-24-66/+29
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils Tests: Move INFRACTION_DESCRIPTION_TEMPLATE to tests fileGravatar ks1292020-06-24-11/+11
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils: Remove unnecessary line splitting on embed footer addingGravatar ks1292020-06-24-3/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Increase coverage of moderation utils testsGravatar ks1292020-06-12-5/+36
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Implement description shortening to infraction notify testsGravatar ks1292020-06-12-8/+27
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Remove deprecated avatar hash in `test_post_user`Gravatar ks1292020-06-12-3/+1
| | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | Mod Utils: Add missing import what was removedGravatar ks1292020-06-11-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Restore `textwrap` import that was removed with merge.
| | | | | | | | * | | | | | | Merge branch 'master' into mod-utils-testsGravatar ks1292020-06-11-1041/+2306
| | | | | | | | |\ \ \ \ \ \ \
| | | | | | | | * | | | | | | | Mod Utils Tests: Replace `has_active_infraction` with `get_active_infraction`Gravatar ks1292020-05-14-5/+5
| | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | Merge branch 'master' into mod-utils-testsGravatar ks1292020-05-14-918/+4352
| | | | | | | | |\ \ \ \ \ \ \ \
| | | | | | | | * | | | | | | | | (Mod Utils): Removed unnecessary `textwrap` importGravatar Karlis S2020-03-13-1/+0
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Mod Utils + Tests): Moved constants from tests to utils, applied changeGravatar Karlis S2020-03-13-34/+34
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Removed Pardon Color constant.Gravatar Karlis S2020-03-13-3/+1
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Removed Infraction Color constant.Gravatar Karlis S2020-03-13-5/+4
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Fixed formatting in `notify_pardon` test.Gravatar Karlis S2020-03-13-1/+2
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Moved `return_value` to `patch` decorator.Gravatar Karlis S2020-03-13-4/+2
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Removed unnecessary mock resetting.Gravatar Karlis S2020-03-13-2/+0
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Added 2 call check to `post_infraction` test.Gravatar Karlis S2020-03-13-2/+2
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | Revise docstrings for moderation util testsGravatar MarkKoz2020-03-12-10/+16
| | | | | | | | | | | | | | | | |
| | | | | | | | * | | | | | | | | (Moderation Utils Tests): Removed `once` from `post_infraction` test due ↵Gravatar Karlis S2020-03-12-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tests failing.