Skip to content

Commit

Permalink
Django 5.1 support
Browse files Browse the repository at this point in the history
  • Loading branch information
Tijani-Dia committed Aug 8, 2024
1 parent c3fe6f1 commit e92bf89
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
10 changes: 4 additions & 6 deletions tests/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,8 @@ def test_track_reverse_many_to_one(self):

category = Category.objects.get(pk=category.pk)
self.assertEqual(category.books.count(), 2)
self.assertQuerysetEqual(
Book.objects.filter(category=category), category.books.all(), ordered=False
self.assertEqual(
list(Book.objects.filter(category=category)), list(category.books.all())
)

tracker = get_instance_tracker(category)
Expand Down Expand Up @@ -236,10 +236,8 @@ def test_reverse_generic_many_to_one_tracker(self):
book = Book.objects.last()

self.assertEqual(book.comments.count(), 2)
self.assertQuerysetEqual(
Comment.objects.filter(object_id=book.pk),
book.comments.all(),
ordered=False,
self.assertEqual(
list(Comment.objects.filter(object_id=book.pk)), list(book.comments.all())
)

tracker = get_instance_tracker(book)
Expand Down
5 changes: 3 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
skipsdist = True
envlist =
python{3.8,3.9,3.10}-django{3.2,4.0,4.1,4.2}
python3.11-django{4.1,4.2,5.0}
python3.12-django{4.2,5.0}
python3.11-django{4.1,4.2,5.0,5.1}
python3.12-django{4.2,5.0,5.1}

basepython =
python3.8: python3.8
Expand All @@ -30,6 +30,7 @@ deps =
django4.1: django>=4.1,<4.2
django4.2: django>=4.2,<5.0
django5.0: django>=5.0,<5.1
django5.1: django>=5.1,<5.2

[testenv:isort]
commands=isort --check-only --diff src/dj_tracker tests setup.py manage.py
Expand Down

0 comments on commit e92bf89

Please sign in to comment.