Register type equality checks for Q and F objects.
Review Request #12039 — Created Feb. 5, 2022 and submitted — Latest diff uploaded
TestCase
now registers the existingassertQEqual()
and a new
assertFEqual()
for comparingQ
andF
objects. This enables
comparison without having to explicitly call those helper methods. This
simplifies unit testing and reduces the chances of issues on different
versions of Django.
Unit tests pass for all supported versions of Python and Django.