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

Unified Diff: LayoutTests/fast/images/viewport-in-standalone-image-document.html

Issue 18034007: Add viewport settings for ImageDocument and MediaDocument (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: LayoutTests Created 7 years, 5 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 | « no previous file | LayoutTests/fast/images/viewport-in-standalone-image-document-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/images/viewport-in-standalone-image-document.html
diff --git a/LayoutTests/fast/images/viewport-in-standalone-image-document.html b/LayoutTests/fast/images/viewport-in-standalone-image-document.html
new file mode 100644
index 0000000000000000000000000000000000000000..838eea5575f7bdef2c89ec2abae8a051b9eb57cd
--- /dev/null
+++ b/LayoutTests/fast/images/viewport-in-standalone-image-document.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <script>
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ }
+
+ function frameLoaded()
+ {
+ var standaloneImageDocument = document.querySelector("iframe").contentDocument;
+ var metaElement = standaloneImageDocument.querySelector("meta");
+
+ if (metaElement && metaElement.name == "viewport" &&
+ metaElement.content == "width=device-width") {
+ document.getElementById("log").textContent = "PASS";
+ }
+ }
+ </script>
+ </head>
+ <body>
+ <p>
+ This tests that a standalone image document has viewport settings.
+ </p>
+ <iframe src="resources/lenna.jpg" onload="frameLoaded()"></iframe>
+ <p id="log">FAIL</p>
+ </body>
+</html>
« no previous file with comments | « no previous file | LayoutTests/fast/images/viewport-in-standalone-image-document-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698