diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
commit | 36d22d82aa202bb199967e9512281e9a53db42c9 (patch) | |
tree | 105e8c98ddea1c1e4784a60a5a6410fa416be2de /testing/web-platform/tests/css/mediaqueries/overflow-media-features.html | |
parent | Initial commit. (diff) | |
download | firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip |
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testing/web-platform/tests/css/mediaqueries/overflow-media-features.html')
-rw-r--r-- | testing/web-platform/tests/css/mediaqueries/overflow-media-features.html | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/testing/web-platform/tests/css/mediaqueries/overflow-media-features.html b/testing/web-platform/tests/css/mediaqueries/overflow-media-features.html new file mode 100644 index 0000000000..fb98331842 --- /dev/null +++ b/testing/web-platform/tests/css/mediaqueries/overflow-media-features.html @@ -0,0 +1,53 @@ +<!DOCTYPE html> +<title>CSS Media Queries Test: overflow media features</title> +<link rel="help" href="https://drafts.csswg.org/mediaqueries-4/#descdef-media-update"> +<meta assert="The test is supposed to be run on computer displays as it will no match otherwise"> +<script type="text/javascript" src="/resources/testharness.js"></script> +<script type="text/javascript" src="/resources/testharnessreport.js"></script> +<script type="text/javascript" src="resources/matchmedia-utils.js"></script> + +<script> +query_should_be_known("(overflow-inline)"); +query_should_be_known("(overflow-inline: none)"); +query_should_be_known("(overflow-inline: scroll)"); + +query_should_be_unknown("overflow-inline"); +query_should_be_unknown("(overflow-inline: ?)"); +query_should_be_unknown("(overflow-inline: 10px)"); +query_should_be_unknown("(overflow-inline: 0)"); + +query_should_be_known("(overflow-block)"); +query_should_be_known("(overflow-block: none)"); +query_should_be_known("(overflow-block: scroll)"); +query_should_be_known("(overflow-block: paged)"); + +query_should_be_unknown("overflow-block"); +query_should_be_unknown("(overflow-block: ?)"); +query_should_be_unknown("(overflow-block: 10px)"); +query_should_be_unknown("(overflow-block: 0)"); + +test(() => { + let match_standard = window.matchMedia("(overflow-inline: scroll)"); + assert_true(match_standard.matches); +}, "Check that overflow-inline: scroll always matches non printing documents"); + +test(() => { + let match_standard = window.matchMedia("(overflow-block: scroll)"); + assert_true(match_standard.matches); +}, "Check that overflow-block: scroll always matches non printing documents"); + +test(() => { + let match_standard = window.matchMedia("(overflow-inline: none)"); + assert_false(match_standard.matches); +}, "Check that overflow-inline: none doesn't match non printing documents"); + +test(() => { + let match_standard = window.matchMedia("(overflow-block: none)"); + assert_false(match_standard.matches); +}, "Check that overflow-block: none doesn't match non printing documents"); + +test(() => { + let match_standard = window.matchMedia("(overflow-block: paged)"); + assert_false(match_standard.matches); +}, "Check that overflow-block: paged doesn't match non printing documents"); +</script> |