Closed Bug 1091579 Opened 10 years ago Closed 10 years ago

Refactor bugscache tests & make them check the matched bug IDs


(Tree Management :: Treeherder, defect, P2)



(Not tracked)



(Reporter: emorley, Assigned: emorley)




(1 file)

Currently the tests for searching the bugscache only check to see whether greater than zero bugs were found, and not how many - or whether it they were even the correct bugs.

In addition, as part of bug 1057359 I'd like to add tests for more search terms, which would be easier to do if the tests used pytest's parametrize.
Ideally at some point we'd break out the refdata.update_bugscache() calls so we don't do unnecessary busy work within each test - however it's no worse off at the moment then previously, so I'll save that for another bug.
Attachment #8514245 - Flags: review?(mdoglio)
Attachment #8514245 - Flags: review?(mdoglio) → review+
Commits pushed to master at
Bug 1091579 - Correct & reformat comments in
Bug 1091579 - Parametrize test_get_open_recent_bug_right_term()
Bug 1091579 - test_get_open_recent_bug_right_term() should check the bug IDs found

...rather than just whether the count of bugs is greater than zero.
Bug 1091579 - Combine the tests for correct and incorrect search terms
Bug 1091579 - Parametrize test_get_all_other_bugs()
Bug 1091579 - test_get_all_other_bugs() should check the bug IDs

...rather than just whether the count of bugs is greater than zero.
Bug 1091579 - Remove the now redundant test_get_all_other_bugs_wrong_term()
Bug 1091579 - Rename SEARCH_TERMS to BUG_SEARCHES
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.