OLD | NEW |
| (Empty) |
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> | |
2 <html> | |
3 <head> | |
4 <script src="../../resources/js-test.js"></script> | |
5 </head> | |
6 <body> | |
7 <p id="description"></p> | |
8 <form method="get"> | |
9 <fieldset name="victim"></fieldset> | |
10 <fieldset name="victim"><input required></fieldset> | |
11 <input name="victim" type="text" value="lorem ipsum"/> | |
12 <button name="victim">lorem ipsum</button> | |
13 <select name="victim"></select> | |
14 <textarea name="victim"></textarea> | |
15 <output name="victim"></output> | |
16 <object name="victim"></object> | |
17 <keygen name="victim"></keygen> | |
18 </form> | |
19 <div id="console"></div> | |
20 <script> | |
21 description("This test checks if checkValidity() returns correctly a true (meani
ng no error) result."); | |
22 | |
23 shouldBe('document.getElementsByTagName("fieldset")[0].checkValidity()', 'true')
; | |
24 shouldBe('document.getElementsByTagName("fieldset")[1].checkValidity()', 'true')
; | |
25 shouldBe('document.getElementsByTagName("input")[1].checkValidity()', 'true'); | |
26 shouldBe('document.getElementsByTagName("button")[0].checkValidity()', 'true'); | |
27 shouldBe('document.getElementsByTagName("select")[0].checkValidity()', 'true'); | |
28 shouldBe('document.getElementsByTagName("textarea")[0].checkValidity()', 'true')
; | |
29 shouldBe('document.getElementsByTagName("output")[0].checkValidity()', 'true'); | |
30 shouldBe('document.getElementsByTagName("object")[0].checkValidity()', 'true'); | |
31 shouldBe('document.getElementsByTagName("keygen")[0].checkValidity()', 'true'); | |
32 </script> | |
33 </body> | |
34 </html> | |
OLD | NEW |