Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/fast/forms/color/display-none-input-color-chooser-shown.html |
| diff --git a/third_party/WebKit/LayoutTests/fast/forms/color/display-none-input-color-chooser-shown.html b/third_party/WebKit/LayoutTests/fast/forms/color/display-none-input-color-chooser-shown.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..f38e2bc15dbae87d19d57780b782dab58cfeb2b6 |
| --- /dev/null |
| +++ b/third_party/WebKit/LayoutTests/fast/forms/color/display-none-input-color-chooser-shown.html |
| @@ -0,0 +1,28 @@ |
| +<!DOCTYPE html> |
| +<script src="../../../resources/testharness.js"></script> |
| +<script src="../../../resources/testharnessreport.js"></script> |
| +<div id="host"> |
| + <input id="colorPick" type="color" /> |
| + <label for="colorPick" id="labelPick">Pick a color</label> |
| +</div> |
| +<script> |
| +test (function() { |
| + assert_true(window.eventSender !== null); |
| +}, "window.eventSender is required for the test to run"); |
| + |
| +test (function() { |
| + var colorPicker = document.getElementById("colorPick"); |
| + colorPicker.style.display = "none"; |
| + var labelPick = document.getElementById("labelPick"); |
| + var x = labelPick.offsetLeft + labelPick.offsetWidth/2; |
| + var y = labelPick.offsetTop + labelPick.offsetHeight/2; |
| + eventSender.mouseMoveTo(x, y); |
| + eventSender.mouseDown(); |
| + eventSender.mouseUp(); |
| + assert_true(testRunner.isChooserShown()); |
| + |
| + var div = document.getElementById('host'); |
| + document.body.removeChild(div); |
|
tkent
2016/07/01 06:54:08
In this case, HTMLInputElement::removedFrom() is c
ramya.v
2016/07/01 09:14:45
Can you please provide a test case of document des
tkent
2016/07/01 09:23:28
for example,
1. click a label associated to input
ramya.v
2016/07/01 10:05:50
Made below test case.
<!DOCTYPE html>
<input type
tkent
2016/07/04 01:25:59
Thank you for the investigation. So, this CL won'
ramya.v
2016/07/04 04:47:56
Filed a bug in crbug.com/625525.
Done.
|
| + setTimeout(function() { assert_false(testRunner.isChooserShown()); }, 5000); |
|
tkent
2016/07/01 06:54:08
This doesn't work. This is a sync test.
ramya.v
2016/07/01 09:14:45
Did not get you? Test case shows pass. Is this li
tkent
2016/07/01 09:23:28
I didn't try this patch. But this assert_false()
ramya.v
2016/07/01 10:05:50
Thanks got your point :) Will remove testing this
|
| +}, "Tests click on label for color picker with display none should show chooser"); |
| +</script> |