Closed Bug 1849873 Opened 2 years ago Closed 2 years ago

Fix some ESLint no-shadow issues in netwerk/test

Categories

(Core :: Networking, task)

task

Tracking

()

RESOLVED FIXED
118 Branch
Tracking Status
firefox118 --- fixed

People

(Reporter: standard8, Assigned: standard8)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

There are currently a lot of ESLint no-shadow warnings in netwerk/test/.

I'm working on changing this rule to be an error instead of a warning - netwerk/test/ is the only place where we currently overriding the rule to be a warning, which was because it was a non-trivial amount of work to do when we initially added enabled the rules on netwerk/test.

This first bug is fixing a selection of issues in the directory, so that I can check that the approaches used are reasonable, before rolling it out to the whole directory.

Pushed by mbanner@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7338770d735a Fix some ESLint no-shadow issues in netwerk/test. r=necko-reviewers,valentin

Backed out for causing failures on test_brotli_http.js

[task 2023-08-24T16:39:39.010Z] 16:39:39     INFO -  TEST-START | netwerk/test/unit/test_brotli_http.js
[task 2023-08-24T16:39:39.671Z] 16:39:39  WARNING -  TEST-UNEXPECTED-FAIL | netwerk/test/unit/test_brotli_http.js | xpcshell return code: 0
[task 2023-08-24T16:39:39.671Z] 16:39:39     INFO -  TEST-INFO took 660ms
[task 2023-08-24T16:39:39.671Z] 16:39:39     INFO -  >>>>>>>
[task 2023-08-24T16:39:39.672Z] 16:39:39     INFO -  (xpcshell/head.js) | test MAIN run_test pending (1)
[task 2023-08-24T16:39:39.672Z] 16:39:39     INFO -  (xpcshell/head.js) | test run_next_test 0 pending (2)
[task 2023-08-24T16:39:39.673Z] 16:39:39     INFO -  (xpcshell/head.js) | test MAIN run_test finished (2)
[task 2023-08-24T16:39:39.673Z] 16:39:39     INFO -  running event loop
[task 2023-08-24T16:39:39.673Z] 16:39:39     INFO -  netwerk/test/unit/test_brotli_http.js | Starting check_brotli
[task 2023-08-24T16:39:39.673Z] 16:39:39     INFO -  (xpcshell/head.js) | test check_brotli pending (2)
[task 2023-08-24T16:39:39.674Z] 16:39:39     INFO -  (xpcshell/head.js) | test run_next_test 0 finished (2)
[task 2023-08-24T16:39:39.674Z] 16:39:39     INFO -  "CONSOLE_MESSAGE: (info) No chrome package registered for chrome://branding/locale/brand.properties"
[task 2023-08-24T16:39:39.674Z] 16:39:39     INFO -  TEST-PASS | netwerk/test/unit/test_brotli_http.js | check_brotli - [check_brotli : 47] Should decode brotli when trustworthy_is_https=true - "hello" == "hello"
[task 2023-08-24T16:39:39.675Z] 16:39:39     INFO -  TEST-PASS | netwerk/test/unit/test_brotli_http.js | check_brotli - [check_brotli : 56] Should not decode brotli when trustworthy_is_https=false - "\\u000b\\u0002\x80hello\\u0003" == "\\u000b\\u0002\x80hello\\u0003"
[task 2023-08-24T16:39:39.676Z] 16:39:39     INFO -  TEST-PASS | netwerk/test/unit/test_brotli_http.js | check_brotli - [check_brotli : 65] Should decode brotli if we set the HTTP accept encoding to include brotli - "hello" == "hello"
[task 2023-08-24T16:39:39.677Z] 16:39:39     INFO -  (xpcshell/head.js) | test run_next_test 1 pending (2)
[task 2023-08-24T16:39:39.677Z] 16:39:39     INFO -  (xpcshell/head.js) | test check_brotli finished (2)
[task 2023-08-24T16:39:39.678Z] 16:39:39     INFO -  netwerk/test/unit/test_brotli_http.js | Starting check_https
[task 2023-08-24T16:39:39.679Z] 16:39:39     INFO -  (xpcshell/head.js) | test check_https pending (2)
[task 2023-08-24T16:39:39.680Z] 16:39:39     INFO -  (xpcshell/head.js) | test run_next_test 1 finished (2)
[task 2023-08-24T16:39:39.680Z] 16:39:39     INFO -  TEST-PASS | netwerk/test/unit/test_brotli_http.js | check_https - [check_https : 101] "gzip, deflate, br" == "gzip, deflate, br"
[task 2023-08-24T16:39:39.681Z] 16:39:39     INFO -  Unexpected exception TypeError: can't access property "status", req is undefined at /builds/worker/workspace/build/tests/xpcshell/tests/netwerk/test/unit/test_brotli_http.js:118
[task 2023-08-24T16:39:39.681Z] 16:39:39     INFO -  check_https@/builds/worker/workspace/build/tests/xpcshell/tests/netwerk/test/unit/test_brotli_http.js:118:5
[task 2023-08-24T16:39:39.682Z] 16:39:39     INFO -  _do_main@/builds/worker/workspace/build/tests/xpcshell/head.js:245:6
[task 2023-08-24T16:39:39.683Z] 16:39:39     INFO -  _execute_test@/builds/worker/workspace/build/tests/xpcshell/head.js:592:5
[task 2023-08-24T16:39:39.683Z] 16:39:39     INFO -  @-e:1:1
[task 2023-08-24T16:39:39.683Z] 16:39:39     INFO -  exiting test
[task 2023-08-24T16:39:39.683Z] 16:39:39     INFO -  "Force a GC"
[task 2023-08-24T16:39:39.684Z] 16:39:39     INFO -  <<<<<<<
Flags: needinfo?(standard8)
Flags: needinfo?(standard8)
Pushed by mbanner@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e5ba3b52ebac Fix some ESLint no-shadow issues in netwerk/test. r=necko-reviewers,valentin
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 118 Branch
Blocks: 1850244
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: