Fix a bunch of errors in query count assertions.

Review Request #12057 — Created Feb. 12, 2022 and submitted — Latest diff uploaded

Information

Review Board
release-5.0.x

Reviewers

With the update to Django, we had a number of tests that were asserting
on specific query counts that needed to be updated. These fall into two
categories:

  1. Datagrid tests were experiencing increased query counts because
    middleware had added a couple simple queries.
  2. Adding items to a many-to-many relation is now done in a single query
    instead of two, so several tests had reduced query counts.

Ran unit tests.

Diff Revision 1 (Latest)

Commits

First Last Summary ID Author
Fix a bunch of errors in query count assertions.
With the update to Django, we had a number of tests that were asserting on specific query counts that needed to be updated. These fall into two categories: 1. Datagrid tests were experiencing increased query counts because middleware had added a couple simple queries. 2. Adding items to a many-to-many relation is now done in a single query instead of two, so several tests had reduced query counts. Testing Done: Ran unit tests.
7330206acb2fd07d29a9182638fe819500c0058e David Trowbridge
reviewboard/datagrids/tests.py
reviewboard/reviews/tests/test_base_review_request_details.py
reviewboard/reviews/tests/test_review_request_page_data.py
Loading...