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

Unified Diff: LayoutTests/http/tests/dom/document-contentType.html

Issue 151653004: Implemented Document.contentType (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase and fixing tests on windows Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/http/conf/lighttpd.conf ('k') | LayoutTests/http/tests/dom/document-contentType-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/http/tests/dom/document-contentType.html
diff --git a/LayoutTests/http/tests/dom/document-contentType.html b/LayoutTests/http/tests/dom/document-contentType.html
new file mode 100644
index 0000000000000000000000000000000000000000..2b7ddf31b6b1e1970ea36cd61c6b64b6984ca76d
--- /dev/null
+++ b/LayoutTests/http/tests/dom/document-contentType.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html>
+<title>document.contentType</title>
+<link rel="help" href="http://dom.spec.whatwg.org/#dom-document-contenttype">
+<script src="/js-test-resources/js-test.js"></script>
+<body>
+<p>
+<iframe data-mt="text/css" src="../resources/dummy.css"></iframe>
+<iframe data-mt="application/x-javascript" src="../resources/dummy.js"></iframe>
+<iframe data-mt="text/html" src="../resources/dummy.html"></iframe>
+<iframe data-mt="text/html" src="resources/send-mime-type.php"></iframe>
+<iframe data-mt="text/xml" src="resources/send-mime-type.php?m=text/xml"></iframe>
+<iframe data-mt="text/xml" src="resources/send-mime-type.php?m=text/xml;charset=utf-8"></iframe>
+<iframe data-mt="text/html" src="javascript:&quot;hello world&quot;;"></iframe>
+<iframe data-mt="text/html" src="about:blank"></iframe>
+<iframe data-mt="text/plain" src="../resources/dummy.txt"></iframe>
+<iframe data-mt="application/xml" src="../resources/dummy.xml"></iframe>
+<iframe data-mt="image/bmp" src="../resources/square20.bmp"></iframe>
+<iframe data-mt="image/gif" src="../resources/square20.gif"></iframe>
+<iframe data-mt="image/jpeg" src="../resources/square20.jpg"></iframe>
+<iframe data-mt="image/png" src="../resources/square20.png"></iframe>
+</p>
+<script>
+var iframes;
+window.onload = function() {
+ iframes = document.getElementsByTagName('iframe');
+ for (var k = 0; iframes[k]; k++) {
+ shouldBeEqualToString('iframes[' + k + '].contentDocument.contentType',
+ iframes[k].dataset.mt);
+ shouldBeEqualToString('iframes[' + k + '].contentDocument.cloneNode(false).contentType',
+ iframes[k].dataset.mt);
+ }
+};
+</script>
« no previous file with comments | « LayoutTests/http/conf/lighttpd.conf ('k') | LayoutTests/http/tests/dom/document-contentType-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698