Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(199)

Side by Side Diff: LayoutTests/fast/dom/DOMImplementation/resources/createDocument-with-used-doctype-frame.html

Issue 22880019: [DOM4] Doctypes now always have a node document and can be moved across document boundaries (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Improve tests Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!doctype html> 1 <!doctype html>
2 <title>document.implementation.createDocument with current document's DOCTYPE</t itle> 2 <html>
3 <head>
4 <script src="../../../js/resources/js-test-pre.js"></script>
5 </head>
3 <body> 6 <body>
4 FAIL (Script did not run);
5 <script> 7 <script>
6 document.body.textContent = "FAIL"; 8 description("document.implementation.createDocument with current document's DOCT YPE.")
7 try { 9
8 document.implementation.createDocument(null, null, document.doctype); 10 var doctype = document.doctype;
9 document.body.textContent = "FAIL (no exception)"; 11 var doc;
10 } 12 shouldNotThrow("doc = document.implementation.createDocument(null, null, documen t.doctype)");
11 catch(e) { 13 shouldBe('doc.doctype', 'doctype');
12 if (e.code === DOMException.WRONG_DOCUMENT_ERR || e.code === DOMException.NO T_SUPPORTED_ERR) 14 shouldBe('doc.firstChild', 'doctype');
13 document.body.textContent = "PASS"; 15 shouldBe('document.doctype', 'null');
14 else
15 document.body.textContent = "FAIL (wrong exception: " + e.code + ")";
16 }
17 </script> 16 </script>
17 </body>
18 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698