<!
DOCTYPE HTML >
<
html >
<
head >
<
title >Test for document.blockParsing</
title >
<
script src=
"chrome://mochikit/content/tests/SimpleTest/SimpleTest.js" ></
script >
<
link rel=
"stylesheet" href=
"chrome://mochikit/content/tests/SimpleTest/test.css" >
</
head >
<
body onload=runTest();>
<
script >
SimpleTest.waitForExplicitFinish();
function checkDoc(aDoc, aScriptState) {
const root = aDoc.documentElement;
let enc = Cu.createDocumentEncoder(
"text/html" );
enc.init(
aDoc,
"text/html" ,
Ci.nsIDocumentEncoder.OutputEncodeBasicEntities |
Ci.nsIDocumentEncoder.OutputLFLineBreak |
Ci.nsIDocumentEncoder.OutputBodyOnly |
Ci.nsIDocumentEncoder.OutputRaw
);
let str = enc.encodeToString();
is(str,
"</noscript> \n" ,
"Serialization matches expectation with scripting " + aScript
State);
}
function runTest() {
const doc = new DOMParser().parseFromString("</noscript> \n" , "text/html" );
checkDoc(doc, "disabled" );
checkDoc(document.getElementsByTagName("iframe" )[0].contentDocument, "enabled" );
SimpleTest.finish();
}
</script >
<iframe src="file_serializer_noscript.html" ></iframe >
</body >
</html >
Messung V0.5 C=100 H=100 G=100
¤ Dauer der Verarbeitung: 0.18 Sekunden
(vorverarbeitet)
¤
*© Formatika GbR, Deutschland