#17600: Error in encapsulates filters (Q)
-------------------------------------+-------------------------------------
Reporter: pmartin | Owner: nobody
Type: Bug | Status: new
Component: Database layer | Version: 1.3
(models, ORM) | Resolution:
Severity: Normal | Triage Stage: Accepted
Keywords: | Needs documentation: 0
Has patch: 1 | Patch needs improvement: 0
Needs tests: 0 | UI/UX: 0
Easy pickings: 0 |
-------------------------------------+-------------------------------------
Comment (by akaariai):
I'm trying to check if the refactor_utils_tree solves this issue.
To me it seems that test_only_orders_with_all_items_having_status_1() is
bogus - it should return both Order: 1 and Order: 2. I can't see where the
restriction is done that _all_ items must have status 1?
The two tests doing assertEqual(qs1, qs2) do not work correctly - while
the querysets do not implement `__eq__` in a way that would be usable
here, so the correct test is assertEqual(list(qs1), list(qs2)). If this is
done, these tests pass.
Apart of that all tests pass, and I think the patch actually solves this
issue. I am wondering if these tests should be added to the patch after
the above corrections, and if modeltests/excludes is the right place. I
might put them into regressiontests/queries, as that is what I usually
run, and contains a lot of similar stuff already.
--
Ticket URL: <https://code.djangoproject.com/ticket/17600#comment:16>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en.