Skip to content

Commit

Permalink
[3.2.x] Refs #31235 -- Improved assertQuerysetEqual() warning message…
Browse files Browse the repository at this point in the history
… with stacklevel=2.

Backport of bc43ae7 from main
  • Loading branch information
claudep authored and felixxm committed Mar 10, 2021
1 parent 4503309 commit 104d617
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions django/test/testcases.py
Original file line number Diff line number Diff line change
Expand Up @@ -1056,6 +1056,7 @@ def assertQuerysetEqual(self, qs, values, transform=None, ordered=True, msg=None
"on a queryset when compared to string values. Set an "
"explicit 'transform' to silence this warning.",
category=RemovedInDjango41Warning,
stacklevel=2,
)
transform = repr
items = qs
Expand Down

0 comments on commit 104d617

Please sign in to comment.