OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <script src="resources/polyfill.js"></script> | |
3 | 2 |
4 <p>Validation should be shown if Shadow DOM has a shadow element.</p> | 3 <p>Validation should be shown if Shadow DOM has a shadow element.</p> |
5 <form id='form' action="input-with-validation.html"> | 4 <form id='form' action="input-with-validation.html"> |
6 <input id=password type=password required maxlength=20 title="Needs at least 8 l
etters.
Should not be identical with the current password."> | 5 <input id=password type=password required maxlength=20 title="Needs at least 8 l
etters.
Should not be identical with the current password."> |
7 <input type=submit id=submit> | 6 <input type=submit id=submit> |
8 </form> | 7 </form> |
9 | 8 |
10 <script> | 9 <script> |
11 if (window.internals) | 10 if (window.internals) |
12 internals.settings.setAuthorShadowDOMForAnyElementEnabled(true); | 11 internals.settings.setAuthorShadowDOMForAnyElementEnabled(true); |
13 | 12 |
14 var input = document.getElementById('password'); | 13 var input = document.getElementById('password'); |
15 var shadowRoot = input.webkitCreateShadowRoot(); | 14 var shadowRoot = input.webkitCreateShadowRoot(); |
16 shadowRoot.innerHTML = "<shadow></shadow>"; | 15 shadowRoot.innerHTML = "<shadow></shadow>"; |
17 | 16 |
18 document.getElementById('submit').click(); | 17 document.getElementById('submit').click(); |
19 if (window.testRunner) { | 18 if (window.testRunner) { |
20 testRunner.waitUntilDone(); | 19 testRunner.waitUntilDone(); |
21 setTimeout(function() { | 20 setTimeout(function() { |
22 testRunner.notifyDone(); | 21 testRunner.notifyDone(); |
23 }, 10); | 22 }, 10); |
24 } | 23 } |
25 </script> | 24 </script> |
26 | 25 |
OLD | NEW |