refactor and move tests

This commit is contained in:
collerek
2020-09-23 10:09:15 +02:00
parent ebd812bf00
commit 798475ae5f
9 changed files with 158 additions and 143 deletions

View File

@ -126,7 +126,9 @@ async def test_quering_of_the_m2m_models(cleanup):
category = await Category.objects.filter(posts__author=guido).get()
assert category == news
# or:
category2 = await Category.objects.filter(posts__author__first_name="Guido").get()
category2 = await Category.objects.filter(
posts__author__first_name="Guido"
).get()
assert category2 == news