Skip media source tests since the feature is not enabled on Windows.
[WebKit-https.git] / LayoutTests / fast / forms / input-type-change-in-onfocus-mouse.html
1 <html>
2 <head>
3     <script>
4     function runTest() {
5         if (window.testRunner)
6             testRunner.dumpAsText();
7         else {
8             alert('This test does not work in Safari.');
9             return;
10         }
11             
12         onblurCalled = false;
13
14         // Simulate a mouse click.
15         eventSender.mouseMoveTo(15, 15);
16         eventSender.mouseDown();
17         eventSender.mouseUp();
18         
19         if (onblurCalled) 
20             return;
21
22         document.getElementById('result').innerHTML = 'SUCCESS';        
23     }
24     </script>
25 </head>
26 <body onload="runTest()">
27     <input id="input" type="text" onfocus="this.setAttribute('type', 'password')" onblur="onblurCalled = true;">
28     <p>
29     This tests that changing an input element's type in its onfocus handler does not cause its onblur handler to be called. If this test is successful, "SUCCESS" should be shown below.
30     </p>
31     <div id="result">FAILURE</div>
32 </body>
33 </html>