Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /fetch/api/headers/header-values-last-event-id.any.html - WPT Dashboard Interop Dashboard
- /fetch/api/headers/header-values-last-event-id.any.serviceworker.html - WPT Dashboard Interop Dashboard
- /fetch/api/headers/header-values-last-event-id.any.sharedworker.html - WPT Dashboard Interop Dashboard
- /fetch/api/headers/header-values-last-event-id.any.worker.html - WPT Dashboard Interop Dashboard
// META: title=Fetch: non-ASCII Last-Event-ID header value
// META: global=window,worker
promise_test(async () => {
const value = "caf\xC3\xA9";
const response = await fetch("../resources/echo-header-bytes.py?headers=last-event-id|x-test", {
headers: { "Last-Event-ID": value, "X-Test": value }
});
assert_equals(await response.text(), "last-event-id: 636166c3a9\nx-test: 636166c3a9");
}, "fetch() sends the bytes of a non-ASCII Last-Event-ID header value unchanged");