diff --git a/boards/tests/test_post.py b/boards/tests/test_post.py --- a/boards/tests/test_post.py +++ b/boards/tests/test_post.py @@ -7,7 +7,7 @@ from boards.models import Tag, Post, Thr class PostTests(TestCase): def _create_post(self): - tag = Tag.objects.create(name='test_tag') + tag, created = Tag.objects.get_or_create(name='test_tag') return Post.objects.create_post(title='title', text='text', tags=[tag])