1
0
Fork 0
firefox/testing/web-platform/tests/client-hints/resources/expect-no-client-hints-headers.html
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

24 lines
620 B
HTML

<!DOCTYPE html>
<html>
<body>
<script>
// This test checks if browser attaches the viewport-width client hint in the
// HTTP request headers.
// resources/echo-client-hints-received.py sets the response headers depending on the set
// of client hints it receives in the request headers.
fetch("../resources/echo-client-hints-received.py").then(r => {
if(r.status == 200 &&
!r.headers.has("viewport-width-received") &&
!r.headers.has("viewport-width-received")) {
window.top.opener.postMessage('PASS', '*');
} else {
window.top.opener.postMessage('FAIL', '*');
}
});
</script>
</body>
</html>