browser_inspector_fission_frame.js (1264B)
1 /* Any copyright is dedicated to the Public Domain. 2 http://creativecommons.org/publicdomain/zero/1.0/ */ 3 "use strict"; 4 5 /** 6 * bug 1673627 - Test that remote iframes with short inline content, 7 * get their inner remote document displayed instead of the inlineTextChild content. 8 */ 9 const TEST_URI = `data:text/html,<div id="root"><iframe src="https://example.com/document-builder.sjs?html=<div id=com>com"><br></iframe></div>`; 10 11 add_task(async function () { 12 const { inspector } = await openInspectorForURL(TEST_URI); 13 const tree = ` 14 id="root" 15 iframe 16 #document 17 html 18 head 19 body 20 id="com"`; 21 await assertMarkupViewAsTree(tree, "#root", inspector); 22 }); 23 24 // Test regular remote frames 25 const FRAME_URL = `https://example.com/document-builder.sjs?html=<div>com`; 26 const TEST_REMOTE_FRAME = `https://example.org/document-builder.sjs?html=<div id="org-root"><iframe src="${FRAME_URL}"></iframe></div>`; 27 add_task(async function () { 28 const { inspector } = await openInspectorForURL(TEST_REMOTE_FRAME); 29 const tree = ` 30 id="org-root" 31 iframe 32 #document 33 html 34 head 35 body 36 com`; 37 await assertMarkupViewAsTree(tree, "#org-root", inspector); 38 });