8000 Add tests for `screenLeft` and `screenTop` · web-platform-tests/wpt@68a0d25 · GitHub
[go: up one dir, main page]

Skip to content

Commit 68a0d25

Browse files
committed
Add tests for screenLeft and screenTop
Matches w3c/csswg-drafts#2669. Note that `screenX` and `screenY` themselves aren't tested at all: #5471
1 parent 937ed3c commit 68a0d25

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

css/cssom-view/screenLeftTop.html

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!DOCTYPE html>
2+
<script src="/resources/testharness.js"></script>
3+
<script src="/resources/testharnessreport.js"></script>
4+
<script>
5+
test(() => {
6+
assert_equals(typeof window.screenLeft, "number", "screenLeft type");
7+
assert_equals(window.screenLeft, window.screenX, "alias of screenX");
8+
}, "screenLeft");
9+
10+
test(() => {
11+
assert_equals(typeof window.screenLeft, "number", "screenTop type");
12+
assert_equals(window.screenLeft, window.screenX, "alias of screenY");
13+
}, "screenTop");
14+
</script>

0 commit comments

Comments
 (0)
0