diff options
author | 2018-12-08 11:55:40 +0000 | |
---|---|---|
committer | 2018-12-08 11:55:40 +0000 | |
commit | 65b3381cfd35949ef457d5f794f83dbd3a4bd45c (patch) | |
tree | 1867912cf613498a4ca56fe3a0ef8660876157e3 /api/tests/test_models.py | |
parent | Renamed class in test_users (diff) | |
parent | Bump minimum DRF version to `3.9.0`. (diff) |
Fixed merge conflicts
Diffstat (limited to 'api/tests/test_models.py')
-rw-r--r-- | api/tests/test_models.py | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/api/tests/test_models.py b/api/tests/test_models.py index 2e606801..1419a7d7 100644 --- a/api/tests/test_models.py +++ b/api/tests/test_models.py @@ -1,9 +1,11 @@ +from datetime import datetime as dt, timezone + from django.test import SimpleTestCase from ..models import ( - DocumentationLink, ModelReprMixin, - OffTopicChannelName, Role, - SnakeFact, SnakeIdiom, + DocumentationLink, Infraction, + ModelReprMixin, OffTopicChannelName, + Role, SnakeFact, SnakeIdiom, SnakeName, SpecialSnake, Tag, User ) @@ -41,13 +43,22 @@ class StringDunderMethodTests(SimpleTestCase): id=5, name='test role', colour=0x5, permissions=0 ), + Tag( + title='bob', + embed={'content': "the builder"} + ), User( id=5, name='bob', discriminator=1, avatar_hash=None ), - Tag( - title='bob', - embed={'content': "the builder"} + Infraction( + user_id=5, actor_id=5, + type='kick', reason='He terk my jerb!' + ), + Infraction( + user_id=5, actor_id=5, hidden=True, + type='kick', reason='He terk my jerb!', + expires_at=dt(5018, 11, 20, 15, 52, tzinfo=timezone.utc) ) ) |