Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/fast/css/pseudo-active-display-none.html |
| diff --git a/third_party/WebKit/LayoutTests/fast/css/pseudo-active-display-none.html b/third_party/WebKit/LayoutTests/fast/css/pseudo-active-display-none.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..460cd568e546126ee41fe8a8f9d5dd0521615f57 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/fast/css/pseudo-active-display-none.html |
| @@ -0,0 +1,36 @@ |
| +<!DOCTYPE html> |
| +<html> |
| +<head> |
|
rune
2016/06/24 12:28:51
Drop html and head.
ramya.v
2016/06/27 06:28:01
Done.
|
| +<script src="../../resources/testharness.js"></script> |
| +<script src="../../resources/testharnessreport.js"></script> |
| +<style> |
| +label { |
| + background-color: black; |
| +} |
| +input:active + label { |
| + background-color: red; |
| +} |
| +#nodisplay { |
| + display: none; |
| +} |
| +</style> |
| +</head> |
| +<body> |
|
rune
2016/06/24 12:28:51
drop </head> and <body>
ramya.v
2016/06/27 06:28:01
Done.
|
| +<input id="nodisplay" type="checkbox"/> |
| +<label id="label1" for="nodisplay">The target input has its display set to none.</label> |
| +<script> |
| +if (window.eventSender) { |
|
rune
2016/06/24 12:28:51
I'd convert this if into a test. E.g.:
test(f
ramya.v
2016/06/27 06:28:01
Done.
|
| + test(function() { |
| + var l1 = document.getElementById("label1"); |
| + var x = l1.offsetLeft + l1.offsetWidth/2; |
| + var y = l1.offsetTop + l1.offsetHeight/2; |
| + eventSender.mouseMoveTo(x, y); |
| + eventSender.mouseDown(); |
| + assert_equals(getComputedStyle(l1).backgroundColor, 'rgb(255, 0, 0)'); |
| + eventSender.mouseUp(); |
| + assert_equals(getComputedStyle(l1).backgroundColor, 'rgb(0, 0, 0)'); |
| + }, "This test performs a check for active pseudo class to be applied for element when its display is set to none."); |
| +} |
| +</script> |
| +</body> |
| +</html> |
|
rune
2016/06/24 12:28:51
Drop </body> and </html>
ramya.v
2016/06/27 06:28:01
Done.
|