Closed Bug 1941800 Opened 1 month ago Closed 1 month ago

[wpt-sync] Sync PR 50098 - Fix mistakes in trusted-types*reporting tests.

Categories

(Core :: DOM: Security, task, P4)

task

Tracking

()

RESOLVED FIXED
136 Branch
Tracking Status
firefox136 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

(Blocks 1 open bug, )

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 50098 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/50098
Details from upstream follow.

Frédéric Wang <fwang@igalia.com> wrote:

Fix mistakes in trusted-types*reporting tests.

  • expect_throws(): move out assert_unreached() out of the try scope. assert_unreached() throws [1] [2] so expect_throws() will not throw in case of failure.

  • trusted-types-reporting.html: Move the elements before the script to make sure they are already in the DOM when the tests are run.

[1] https://github.com/web-platform-tests/wpt/blob/070a67f19da0b454068bc38ef40904403e5edca0/resources/testharness.js#L2391
[2] https://github.com/web-platform-tests/wpt/blob/070a67f19da0b454068bc38ef40904403e5edca0/resources/testharness.js#L4544

Component: web-platform-tests → DOM: Security
Product: Testing → Core

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, and Chrome on GitHub CI

Total 4 tests and 19 subtests

Status Summary

Firefox

OK : 1
PASS : 8
FAIL : 11[Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] 19[GitHub]
ERROR : 1[Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-opt] 4[GitHub]

Chrome

OK : 3
FAIL : 8
TIMEOUT: 2
NOTRUN : 18

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

  • /trusted-types/trusted-types-eval-reporting-no-unsafe-eval.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
  • /trusted-types/trusted-types-eval-reporting-report-only.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
  • /trusted-types/trusted-types-eval-reporting.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
  • /trusted-types/trusted-types-reporting.html [wpt.fyi]: ERROR [Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-opt, GitHub], OK [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-64-2009-qr-debug] (Chrome: TIMEOUT)
    • Trusted Type violation report: creating a forbidden policy.: FAIL (Chrome: TIMEOUT)
    • Trusted Type violation report: creating a report-only-forbidden policy.: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: creating a forbidden-but-not-reported policy.: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: blocked URI and sample for insertAdjacentHTML: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: assign string to script url: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: assign string to html: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: assign trusted script to script; no report: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: assign trusted HTML to html; no report: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: sample for innerHTML assignment: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: sample for text assignment: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: sample for script.src assignment: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: sample for script innerText assignment: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: sample for SVGScriptElement href assignment: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: sample for SVGScriptElement href assignment by setAttribute: FAIL [GitHub], PASS [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: NOTRUN)
    • Trusted Type violation report: sample for SVGScriptElement text assignment: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: sample for eval: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: large values should be handled sanely.: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: sample for custom element assignment: FAIL (Chrome: NOTRUN)
    • Trusted Type violation report: Worker constructor: FAIL (Chrome: NOTRUN)

Tests Disabled in Gecko Infrastructure

  • /trusted-types/trusted-types-eval-reporting-no-unsafe-eval.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
  • /trusted-types/trusted-types-eval-reporting-report-only.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
  • /trusted-types/trusted-types-eval-reporting.html [wpt.fyi]: ERROR [GitHub], SKIP [Gecko-android-em-7.0-x86_64-lite-qr-opt-geckoview, Gecko-android-em-7.0-x86_64-qr-debug-geckoview, Gecko-android-em-7.0-x86_64-qr-opt-geckoview, Gecko-linux1804-64-qr-debug, Gecko-linux1804-64-qr-opt, Gecko-windows11-32-2009-qr-debug, Gecko-windows11-32-2009-qr-opt, Gecko-windows11-64-2009-qr-debug, Gecko-windows11-64-2009-qr-opt] (Chrome: OK)
Blocks: 1939805
Blocks: 1940049
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/2abbfca98a22 [wpt PR 50098] - Fix mistakes in trusted-types*reporting tests., a=testonly https://hg.mozilla.org/integration/autoland/rev/ede29c142eb6 [wpt PR 50098] - Update wpt metadata, a=testonly
Status: NEW → RESOLVED
Closed: 1 month ago
Resolution: --- → FIXED
Target Milestone: --- → 136 Branch
You need to log in before you can comment on or make changes to this bug.