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

Unified Diff: third_party/WebKit/LayoutTests/fast/images/jpeg-yuv-progressive-image.html

Issue 1845223005: Add Progressive JPEG YUV decoding layout tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Yeap, need to add virtual tests to TestExpectations also Created 4 years, 8 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
Index: third_party/WebKit/LayoutTests/fast/images/jpeg-yuv-progressive-image.html
diff --git a/third_party/WebKit/LayoutTests/fast/images/jpeg-yuv-progressive-image.html b/third_party/WebKit/LayoutTests/fast/images/jpeg-yuv-progressive-image.html
new file mode 100644
index 0000000000000000000000000000000000000000..de250a8333d71a09765dae0fe1c7f17782b32cee
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/images/jpeg-yuv-progressive-image.html
@@ -0,0 +1,48 @@
+<!DOCTYPE html>
+<!-- test case for crbug.com/597127 -->
+<html>
+<head>
+<!-- Use a <meta> viewport, see http://crbug.com/598949 -->
+<meta name="viewport" content="width=device-width, minimum-scale=1.0">
+<style>
+ img {
+ border: 2px solid black;
+ margin: 5px 5px 0px 5px;
+ padding: 2px;
+ width: 150px;
+ height: 150px;
+ }
+</style>
+</head>
+
+<script>
+if (window.testRunner) {
+ testRunner.dumpAsTextWithPixelResults();
+ testRunner.waitUntilDone();
+}
+
+var totalTestImages = 4;
+
+window.onload = function() {
+ for (var x = 0; x < totalTestImages; ++x)
+ loadImage(x);
+};
+
+function loadImage(x) {
+ var image = new Image();
+
+ document.body.appendChild(image);
+
+ image.onload = function() {
+ setTimeout(imageLoaded, 0, x + 1);
+ };
+
+ image.src = 'resources/ycbcr-progressive-00' + x + '.jpg';
+}
+
+function imageLoaded(x) {
+ if (x >= totalTestImages && window.testRunner)
+ testRunner.notifyDone();
+}
+</script>
+</html>

Powered by Google App Engine
This is Rietveld 408576698