Closed Bug 1315781 Opened 9 years ago Closed 9 years ago

Enable no-shadow rule for eslint for xpcshell mochitests

Categories

(Firefox :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 52
Tracking Status
firefox52 --- fixed

People

(Reporter: jaws, Assigned: jaws)

References

Details

Attachments

(1 file)

+++ This bug was initially created as a clone of Bug #1314474 +++ Enabling the no-shadow rule for all of m-c has thousands of errors, so this approach is to fix the no-shadow rule piecemeal. The attached patch fixes the no-shadow rule for xpcshell tests. Bug 1314474 fixed them for mochitests.
No longer depends on: 1314474
Comment on attachment 8808482 [details] Bug 1315781 - Enable no-shadow rule for eslint for xpcshell mochitests. https://reviewboard.mozilla.org/r/91312/#review91418 Thanks for doing this! I noticed some nits while skimming the PSM changes... ::: security/manager/ssl/tests/unit/test_cert_keyUsage.js:53 (Diff revision 1) > addCertFromFile(certdb, "test_cert_keyUsage/" + ca + ".pem", "CTu,CTu,CTu"); > - let cert = constructCertFromFile("test_cert_keyUsage/" + ca + ".pem"); > - yield asyncTestCertificateUsages(certdb, cert, expectedUsagesMap[ca]); > + let caCert = constructCertFromFile("test_cert_keyUsage/" + ca + ".pem"); > + yield asyncTestCertificateUsages(certdb, caCert, expectedUsagesMap[ca]); > for (let ee of eeList) { > let eeFullName = ee + "-" + ca; > - let cert = constructCertFromFile("test_cert_keyUsage/" + eeFullName + ".pem"); > + let fullNameCert = constructCertFromFile("test_cert_keyUsage/" + eeFullName + ".pem"); Nit: `eeCert` would be a better name for this. ::: security/manager/ssl/tests/unit/test_weak_crypto.js:126 (Diff revision 1) > } > }, > > - onInputStreamReady: function(input) { > + onInputStreamReady: function(streamReadyInput) { > try { > - let data = NetUtil.readInputStreamToString(input, input.available()); > + let data = NetUtil.readInputStreamToString(streamReadyInput, streamReadyInput.available()); Nit: PSM code generally tries to stick to max 80 chars or so per line.
Comment on attachment 8808482 [details] Bug 1315781 - Enable no-shadow rule for eslint for xpcshell mochitests. https://reviewboard.mozilla.org/r/91312/#review91754
Attachment #8808482 - Flags: review?(dtownsend) → review+
Pushed by jwein@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f6f28be8d8f2 Enable no-shadow rule for eslint for xpcshell mochitests. r=mossop
Sorry had to back out for XPCShell test timed out, i.e., https://treeherder.mozilla.org/logviewer.html#?job_id=6434418&repo=autoland#L10351
Flags: needinfo?(jaws)
Backout by ihsiao@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/577d70d19512 Backed out changeset f6f28be8d8f2 for XPCShell test timed out
Pushed by jwein@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f3491aaeac27 Enable no-shadow rule for eslint for xpcshell mochitests. r=mossop
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 52
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: