Closed Bug 1348720 Opened 8 years ago Closed 8 years ago

More rigorous alert handling for tests

Categories

(NSS :: Test, enhancement)

3.30
enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mt, Assigned: mt)

References

Details

Bug 956866 added the ability to register for alerts, both sending and receiving. However, its integration into the gtests was only hastily done. We can and should use this capability to monitor for all alerts that are sent and received in the tests. Counting is not the best technique for handling alerts, because if n>1 (which it doesn't need to be) then you only count the existence of the alert, you don't get to check that the alert itself was correct. This uses an expectation-based system, where you name the alert that is expected. When the callback happens, the expectation is checked and then reset. https://nss-review.dev.mozaws.net/D258
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → 3.31
Version: trunk → 3.30
You need to log in before you can comment on or make changes to this bug.