1
0
Fork 0
firefox/testing/web-platform/tests/fetch/api/response/response-headers-guard.any.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

8 lines
391 B
JavaScript

// META: global=window,worker
// META: title=Response: error static method
promise_test (async () => {
const response = await fetch("../resources/data.json");
assert_throws_js(TypeError, () => { response.headers.append("name", "value"); });
assert_not_equals(response.headers.get("name"), "value", "response headers should be immutable");
}, "Ensure response headers are immutable");