Closed Bug 605565 Opened 14 years ago Closed 14 years ago

Re-enable JSterm helper tests

Categories

(DevTools :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: rcampbell, Assigned: rcampbell)

References

Details

Attachments

(1 file)

During a preliminary once-over of bug 599940, gavin discovered that the jsterm helper tests were not ported over during the deconstruction of HUDServiceTestsAll.

see:
http://hg.mozilla.org/mozilla-central/rev/6160fe29dd37#l3.7

This bug is to add them back.
Assignee: nobody → rcampbell
Status: NEW → ASSIGNED
Attachment #484421 - Flags: review?(gavin.sharp)
Blocks: 599940
Comment on attachment 484421 [details] [diff] [review]
[checked-in] webconsole_jsterm

Seems like you could add a checkResult() helper that does the querySelector/is() checks:

function checkResult(msg, desc, lines) {
  let labels = jsterm.outputNode.querySelectorAll(".jsterm-output-line");
  is(labels.length, lines, "correct number of results shown for " + desc);
  is(labels[lines-1].textContent.trim(), msg, "correct message shown for " + desc);
}
Attachment #484421 - Flags: review?(gavin.sharp) → review+
Comment on attachment 484421 [details] [diff] [review]
[checked-in] webconsole_jsterm

http://hg.mozilla.org/mozilla-central/rev/189f8ed29460
Attachment #484421 - Attachment description: webconsole_jsterm → [checked-in] webconsole_jsterm
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: