| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="/js-test-resources/js-test-pre.js"></script> | 4 <script src="/js-test-resources/js-test-pre.js"></script> |
| 5 <script> | 5 <script> |
| 6 description('This tests that XMLHttpRequest overrideMimeType() properly
handles mixed case MIME strings.'); | 6 description('This tests that XMLHttpRequest overrideMimeType() properly
handles mixed case MIME strings.'); |
| 7 window.jsTestIsAsync = true; | 7 window.jsTestIsAsync = true; |
| 8 | 8 |
| 9 var xhr = new XMLHttpRequest(), | 9 var xhr = new XMLHttpRequest(), |
| 10 url = 'resources/load-icon.xhtml'; | 10 url = 'resources/load-icon.xhtml'; |
| 11 xhr.onload = function() { | 11 xhr.onload = function() { |
| 12 shouldBeNonNull('xhr.responseXML'); | 12 shouldBeNonNull('xhr.responseXML'); |
| 13 finishJSTest(); | 13 finishJSTest(); |
| 14 }; | 14 }; |
| 15 xhr.onerror = function() { | 15 xhr.onerror = function() { |
| 16 testFailed('The XHR request to an existing resource failed: "' + url
+ '"'); | 16 testFailed('The XHR request to an existing resource failed: "' + url
+ '"'); |
| 17 finishJSTest(); | 17 finishJSTest(); |
| 18 }; | 18 }; |
| 19 xhr.open('GET', url); | 19 xhr.open('GET', url); |
| 20 xhr.overrideMimeType('Application/Xhtml+Xml'); | 20 xhr.overrideMimeType('Application/Xhtml+Xml'); |
| 21 xhr.responseType = 'document'; | 21 xhr.responseType = 'document'; |
| 22 xhr.send(null); | 22 xhr.send(null); |
| 23 </script> | 23 </script> |
| 24 <script src="/js-test-resources/js-test-post.js"></script> | |
| 25 </head> | 24 </head> |
| 26 <body> | 25 <body> |
| 27 <div id="description"></div> | 26 <div id="description"></div> |
| 28 <div id="console"></div> | 27 <div id="console"></div> |
| 29 </body> | 28 </body> |
| 30 </html> | 29 </html> |
| OLD | NEW |