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 /layout/style/test/test_bug379440.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 'layout/style/test/test_bug379440.html')
-rw-r--r-- | layout/style/test/test_bug379440.html | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/layout/style/test/test_bug379440.html b/layout/style/test/test_bug379440.html new file mode 100644 index 0000000000..56644f85cb --- /dev/null +++ b/layout/style/test/test_bug379440.html @@ -0,0 +1,74 @@ +<!DOCTYPE HTML> +<html> +<!-- +https://bugzilla.mozilla.org/show_bug.cgi?id=379440 +--> +<head> + <title>Test for Bug 379440</title> + <script src="/tests/SimpleTest/SimpleTest.js"></script> + <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" /> + <style type="text/css"> + #display > * { cursor: auto } + #t1 { + cursor: url(file:///tmp/foo), url(file:///c|/), + url(http://example.com/), crosshair; + } + #t2 { + cursor: url(file:///tmp/foo), url(file:///c|/), crosshair; + } + #t3 { + cursor: url(http://example.com/), crosshair; + } + #t4 { + cursor: url(http://example.com/); + } + #t5 { + cursor: url(http://example.com/), no-such-cursor-exists; + } + #t6 { + cursor: crosshair; + } + #t7 { + cursor: no-such-cursor-exists; + } + </style> +</head> +<body> +<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=379440">Mozilla Bug 379440</a> +<p id="display"> + <div id="t1"> </div> + <div id="t2"></div> + <div id="t3"></div> + <div id="t4"></div> + <div id="t5"></div> + <div id="t6"></div> + <div id="t7"></div> +</p> +<div id="content" style="display: none"> + +</div> +<pre id="test"> +<script class="testbody" type="text/javascript"> + +/** Test for Bug 379440 **/ + +function cur(id) { + return document.defaultView.getComputedStyle($(id)).cursor; +} + +is(cur("t1"), 'url("file:///tmp/foo"), url("file:///c:/"), ' + + 'url("http://example.com/"), crosshair', + "Serialize unloadable URLs using their specified value"); +is(cur("t2"), 'url("file:///tmp/foo"), url("file:///c:/"), crosshair', + "Serialize unloadable URLs using their specified value"); +is(cur("t3"), 'url("http://example.com/"), crosshair', "URI + fallback"); +is(cur("t4"), "auto", "Must have a fallback"); +is(cur("t5"), "auto", "Fallback must be recognized"); +is(cur("t6"), "crosshair", "Just a fallback"); +is(cur("t7"), "auto", "Invalid fallback means ignore"); + +</script> +</pre> +</body> +</html> + |