Closed
Bug 1605370
Opened 5 years ago
Closed 5 years ago
Cleanup DevTools tests using ok() incorrectly
Categories
(DevTools :: General, task, P3)
DevTools
General
Tracking
(firefox73 fixed)
RESOLVED
FIXED
Firefox 73
| Tracking | Status | |
|---|---|---|
| firefox73 | --- | fixed |
People
(Reporter: jdescottes, Assigned: jdescottes)
Details
Attachments
(1 file)
Tests in the codebase sometimes use ok() as an info() equivalent:
ok(true, "message");
Not ideal, but sometimes needed, if there are no other asserts in the test and not worth updating.
However we also have completely wrong usage of ok():
https://searchfox.org/mozilla-central/search?q=ok%5C(%5C%22%5B%5E%22%5D*%5C%22%5C)&case=true®exp=true&path=
Here, ok() is only called with a string, eg ok("Manifest is being displayed");. This will count as a valid assertions, but in the logs this will show up as:
PASS undefined assertion name -
We should switch those to ok(true, "message") at least
| Assignee | ||
Comment 1•5 years ago
|
||
Pushed by jdescottes@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/021d07025dad
Rewrite ok(message) as ok(true, message) in DevTools tests r=daisuke
Comment 3•5 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
status-firefox73:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 73
You need to log in
before you can comment on or make changes to this bug.
Description
•