summaryrefslogtreecommitdiffstats
path: root/LayoutTests/fast/encoding/css-cached-bom.html
diff options
context:
space:
mode:
Diffstat (limited to 'LayoutTests/fast/encoding/css-cached-bom.html')
-rw-r--r--LayoutTests/fast/encoding/css-cached-bom.html20
1 files changed, 20 insertions, 0 deletions
diff --git a/LayoutTests/fast/encoding/css-cached-bom.html b/LayoutTests/fast/encoding/css-cached-bom.html
new file mode 100644
index 0000000..a6e75eb
--- /dev/null
+++ b/LayoutTests/fast/encoding/css-cached-bom.html
@@ -0,0 +1,20 @@
+<script>
+if (window.layoutTestController) {
+ layoutTestController.dumpAsText();
+ layoutTestController.waitUntilDone();
+}
+function frameLoaded() {
+ if (document.getElementById('f').contentDocument.styleSheets[0].cssRules[0].selectorText == "#success::before")
+ document.getElementById('result').innerHTML = "SUCCESS";
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+}
+</script>
+<link rel=stylesheet href=resources/utf-16-little-endian.css>
+<!-- This halts the parsing until stylesheet has been loaded -->
+<script src=does_not_exists.js></script>
+<div>Test that stylesheet with BOM is correctly parsed when loaded from cache. You should see word SUCCESS below.</div>
+<!-- Load the stylesheet to a different frame. This will use a cached copy of the stylesheet. -->
+<iframe id=f src=resources/css-cached-bom-frame.html></iframe>
+<div id=result>FAIL</div>
+