1
0
Fork 0
firefox/testing/web-platform/tests/content-security-policy/script-src/inlineSuccessTest.js
Daniel Baumann 5e9a113729
Adding upstream version 140.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-25 09:37:52 +02:00

12 lines
No EOL
437 B
JavaScript

var t_spv = async_test("Should not fire policy violation events");
window.addEventListener("securitypolicyviolation", t_spv.unreached_func("Should have not fired any securitypolicyviolation event"));
var inlineRan = false;
onload = function() {
test(function() {
assert_true(inlineRan, 'Unsafe inline script ran.')},
'Inline script in a script tag should run with an unsafe-inline directive'
);
t_spv.done();
}