aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm
diff options
context:
space:
mode:
authorGravatar epoger@google.com <epoger@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-11-28 20:08:32 +0000
committerGravatar epoger@google.com <epoger@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-11-28 20:08:32 +0000
commit570aafe9c107f35e4250e2830376780d5fe3421c (patch)
tree7f1f251c3f8299588aea17415cb64f0273a3244e /gm
parent629ab540667422d3edcb97c51e9628b7051e1ba4 (diff)
Update gm self-test to pass again after r6585
Now depends on only "dashing2" test, not all tests whose name starts with "dashing", so it should be more resilient in the face of further changes. TBR=borenet,robertphillips Review URL: https://codereview.appspot.com/6844104 git-svn-id: http://skia.googlecode.com/svn/trunk@6588 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'gm')
-rw-r--r--gm/tests/inputs/dashing-correct-images/4444/dashing.pngbin1875 -> 0 bytes
-rw-r--r--gm/tests/inputs/dashing-incorrect-images/4444/dashing.pngbin2797 -> 0 bytes
-rw-r--r--gm/tests/inputs/different-pixels/4444/dashing2.pngbin0 -> 24979 bytes
-rw-r--r--gm/tests/inputs/identical-bytes/4444/dashing2.png (renamed from gm/tests/inputs/dashing-correct-images/4444/dashing2.png)bin23808 -> 23808 bytes
-rw-r--r--gm/tests/inputs/identical-pixels/4444/dashing2.png (renamed from gm/tests/inputs/dashing-incorrect-images/4444/dashing2.png)bin22723 -> 22723 bytes
-rw-r--r--gm/tests/outputs/compared-against-different-pixels/output-expected/command_line1
-rw-r--r--gm/tests/outputs/compared-against-different-pixels/output-expected/images/4444/dashing2.png (renamed from gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing2.png)bin23808 -> 23808 bytes
-rw-r--r--gm/tests/outputs/compared-against-different-pixels/output-expected/return_value (renamed from gm/tests/outputs/dashing-compared-against-incorrect/output-expected/return_value)0
-rw-r--r--gm/tests/outputs/compared-against-different-pixels/output-expected/stdout6
-rw-r--r--gm/tests/outputs/compared-against-identical-bytes/output-expected/command_line1
-rw-r--r--gm/tests/outputs/compared-against-identical-bytes/output-expected/images/4444/dashing2.png (renamed from gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing2.png)bin23808 -> 23808 bytes
-rw-r--r--gm/tests/outputs/compared-against-identical-bytes/output-expected/return_value (renamed from gm/tests/outputs/dashing-compared-against-correct/output-expected/return_value)0
-rw-r--r--gm/tests/outputs/compared-against-identical-bytes/output-expected/stdout4
-rw-r--r--gm/tests/outputs/compared-against-identical-pixels/output-expected/command_line1
-rw-r--r--gm/tests/outputs/compared-against-identical-pixels/output-expected/images/4444/dashing2.pngbin0 -> 23808 bytes
-rw-r--r--gm/tests/outputs/compared-against-identical-pixels/output-expected/return_value1
-rw-r--r--gm/tests/outputs/compared-against-identical-pixels/output-expected/stdout4
-rw-r--r--gm/tests/outputs/dashing-compared-against-correct/output-expected/command_line1
-rw-r--r--gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing.pngbin1875 -> 0 bytes
-rw-r--r--gm/tests/outputs/dashing-compared-against-correct/output-expected/stdout5
-rw-r--r--gm/tests/outputs/dashing-compared-against-incorrect/output-expected/command_line1
-rw-r--r--gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing.pngbin1875 -> 0 bytes
-rw-r--r--gm/tests/outputs/dashing-compared-against-incorrect/output-expected/stdout7
-rwxr-xr-xgm/tests/run.sh10
24 files changed, 25 insertions, 17 deletions
diff --git a/gm/tests/inputs/dashing-correct-images/4444/dashing.png b/gm/tests/inputs/dashing-correct-images/4444/dashing.png
deleted file mode 100644
index e201a72d68..0000000000
--- a/gm/tests/inputs/dashing-correct-images/4444/dashing.png
+++ /dev/null
Binary files differ
diff --git a/gm/tests/inputs/dashing-incorrect-images/4444/dashing.png b/gm/tests/inputs/dashing-incorrect-images/4444/dashing.png
deleted file mode 100644
index c319eabb2e..0000000000
--- a/gm/tests/inputs/dashing-incorrect-images/4444/dashing.png
+++ /dev/null
Binary files differ
diff --git a/gm/tests/inputs/different-pixels/4444/dashing2.png b/gm/tests/inputs/different-pixels/4444/dashing2.png
new file mode 100644
index 0000000000..bb94276936
--- /dev/null
+++ b/gm/tests/inputs/different-pixels/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/inputs/dashing-correct-images/4444/dashing2.png b/gm/tests/inputs/identical-bytes/4444/dashing2.png
index 91d37eb901..91d37eb901 100644
--- a/gm/tests/inputs/dashing-correct-images/4444/dashing2.png
+++ b/gm/tests/inputs/identical-bytes/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/inputs/dashing-incorrect-images/4444/dashing2.png b/gm/tests/inputs/identical-pixels/4444/dashing2.png
index ed37a88211..ed37a88211 100644
--- a/gm/tests/inputs/dashing-incorrect-images/4444/dashing2.png
+++ b/gm/tests/inputs/identical-pixels/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/outputs/compared-against-different-pixels/output-expected/command_line b/gm/tests/outputs/compared-against-different-pixels/output-expected/command_line
new file mode 100644
index 0000000000..1bcbead0e0
--- /dev/null
+++ b/gm/tests/outputs/compared-against-different-pixels/output-expected/command_line
@@ -0,0 +1 @@
+out/Debug/gm --hierarchy --match dashing2 --config 4444 -r gm/tests/inputs/different-pixels -w gm/tests/outputs/compared-against-different-pixels/output-actual/images
diff --git a/gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing2.png b/gm/tests/outputs/compared-against-different-pixels/output-expected/images/4444/dashing2.png
index 91d37eb901..91d37eb901 100644
--- a/gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing2.png
+++ b/gm/tests/outputs/compared-against-different-pixels/output-expected/images/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/return_value b/gm/tests/outputs/compared-against-different-pixels/output-expected/return_value
index ace9d03621..ace9d03621 100644
--- a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/return_value
+++ b/gm/tests/outputs/compared-against-different-pixels/output-expected/return_value
diff --git a/gm/tests/outputs/compared-against-different-pixels/output-expected/stdout b/gm/tests/outputs/compared-against-different-pixels/output-expected/stdout
new file mode 100644
index 0000000000..1eda31c7db
--- /dev/null
+++ b/gm/tests/outputs/compared-against-different-pixels/output-expected/stdout
@@ -0,0 +1,6 @@
+reading from gm/tests/inputs/different-pixels
+writing to gm/tests/outputs/compared-against-different-pixels/output-actual/images
+drawing... dashing2 [640 480]
+----- max pixel mismatch for 4444/dashing2 is 51
+Ran 1 tests: 0 passed, 1 failed, 0 missing reference images
+ 4444/dashing2 pixel_error 51
diff --git a/gm/tests/outputs/compared-against-identical-bytes/output-expected/command_line b/gm/tests/outputs/compared-against-identical-bytes/output-expected/command_line
new file mode 100644
index 0000000000..c70d01dc8c
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-bytes/output-expected/command_line
@@ -0,0 +1 @@
+out/Debug/gm --hierarchy --match dashing2 --config 4444 -r gm/tests/inputs/identical-bytes -w gm/tests/outputs/compared-against-identical-bytes/output-actual/images
diff --git a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing2.png b/gm/tests/outputs/compared-against-identical-bytes/output-expected/images/4444/dashing2.png
index 91d37eb901..91d37eb901 100644
--- a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing2.png
+++ b/gm/tests/outputs/compared-against-identical-bytes/output-expected/images/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/outputs/dashing-compared-against-correct/output-expected/return_value b/gm/tests/outputs/compared-against-identical-bytes/output-expected/return_value
index 573541ac97..573541ac97 100644
--- a/gm/tests/outputs/dashing-compared-against-correct/output-expected/return_value
+++ b/gm/tests/outputs/compared-against-identical-bytes/output-expected/return_value
diff --git a/gm/tests/outputs/compared-against-identical-bytes/output-expected/stdout b/gm/tests/outputs/compared-against-identical-bytes/output-expected/stdout
new file mode 100644
index 0000000000..301f17f5e7
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-bytes/output-expected/stdout
@@ -0,0 +1,4 @@
+reading from gm/tests/inputs/identical-bytes
+writing to gm/tests/outputs/compared-against-identical-bytes/output-actual/images
+drawing... dashing2 [640 480]
+Ran 1 tests: 1 passed, 0 failed, 0 missing reference images
diff --git a/gm/tests/outputs/compared-against-identical-pixels/output-expected/command_line b/gm/tests/outputs/compared-against-identical-pixels/output-expected/command_line
new file mode 100644
index 0000000000..d6b58501d6
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-pixels/output-expected/command_line
@@ -0,0 +1 @@
+out/Debug/gm --hierarchy --match dashing2 --config 4444 -r gm/tests/inputs/identical-pixels -w gm/tests/outputs/compared-against-identical-pixels/output-actual/images
diff --git a/gm/tests/outputs/compared-against-identical-pixels/output-expected/images/4444/dashing2.png b/gm/tests/outputs/compared-against-identical-pixels/output-expected/images/4444/dashing2.png
new file mode 100644
index 0000000000..91d37eb901
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-pixels/output-expected/images/4444/dashing2.png
Binary files differ
diff --git a/gm/tests/outputs/compared-against-identical-pixels/output-expected/return_value b/gm/tests/outputs/compared-against-identical-pixels/output-expected/return_value
new file mode 100644
index 0000000000..573541ac97
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-pixels/output-expected/return_value
@@ -0,0 +1 @@
+0
diff --git a/gm/tests/outputs/compared-against-identical-pixels/output-expected/stdout b/gm/tests/outputs/compared-against-identical-pixels/output-expected/stdout
new file mode 100644
index 0000000000..00868ac5b1
--- /dev/null
+++ b/gm/tests/outputs/compared-against-identical-pixels/output-expected/stdout
@@ -0,0 +1,4 @@
+reading from gm/tests/inputs/identical-pixels
+writing to gm/tests/outputs/compared-against-identical-pixels/output-actual/images
+drawing... dashing2 [640 480]
+Ran 1 tests: 1 passed, 0 failed, 0 missing reference images
diff --git a/gm/tests/outputs/dashing-compared-against-correct/output-expected/command_line b/gm/tests/outputs/dashing-compared-against-correct/output-expected/command_line
deleted file mode 100644
index 8a95ecd2bc..0000000000
--- a/gm/tests/outputs/dashing-compared-against-correct/output-expected/command_line
+++ /dev/null
@@ -1 +0,0 @@
-out/Debug/gm --hierarchy --match dashing --config 4444 -r gm/tests/inputs/dashing-correct-images -w gm/tests/outputs/dashing-compared-against-correct/output-actual/images
diff --git a/gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing.png b/gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing.png
deleted file mode 100644
index e201a72d68..0000000000
--- a/gm/tests/outputs/dashing-compared-against-correct/output-expected/images/4444/dashing.png
+++ /dev/null
Binary files differ
diff --git a/gm/tests/outputs/dashing-compared-against-correct/output-expected/stdout b/gm/tests/outputs/dashing-compared-against-correct/output-expected/stdout
deleted file mode 100644
index d7f2c6bb08..0000000000
--- a/gm/tests/outputs/dashing-compared-against-correct/output-expected/stdout
+++ /dev/null
@@ -1,5 +0,0 @@
-reading from gm/tests/inputs/dashing-correct-images
-writing to gm/tests/outputs/dashing-compared-against-correct/output-actual/images
-drawing... dashing2 [640 480]
-drawing... dashing [640 300]
-Ran 2 tests: 2 passed, 0 failed, 0 missing reference images
diff --git a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/command_line b/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/command_line
deleted file mode 100644
index 423a7f1ba8..0000000000
--- a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/command_line
+++ /dev/null
@@ -1 +0,0 @@
-out/Debug/gm --hierarchy --match dashing --config 4444 -r gm/tests/inputs/dashing-incorrect-images -w gm/tests/outputs/dashing-compared-against-incorrect/output-actual/images
diff --git a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing.png b/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing.png
deleted file mode 100644
index e201a72d68..0000000000
--- a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/images/4444/dashing.png
+++ /dev/null
Binary files differ
diff --git a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/stdout b/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/stdout
deleted file mode 100644
index 10956becc8..0000000000
--- a/gm/tests/outputs/dashing-compared-against-incorrect/output-expected/stdout
+++ /dev/null
@@ -1,7 +0,0 @@
-reading from gm/tests/inputs/dashing-incorrect-images
-writing to gm/tests/outputs/dashing-compared-against-incorrect/output-actual/images
-drawing... dashing2 [640 480]
-drawing... dashing [640 300]
------ max pixel mismatch for 4444/dashing is 51
-Ran 2 tests: 1 passed, 1 failed, 0 missing reference images
- 4444/dashing pixel_error 51
diff --git a/gm/tests/run.sh b/gm/tests/run.sh
index 103a71f816..acf4b5feef 100755
--- a/gm/tests/run.sh
+++ b/gm/tests/run.sh
@@ -63,9 +63,13 @@ GM_TESTDIR=gm/tests
GM_INPUTS=$GM_TESTDIR/inputs
GM_OUTPUTS=$GM_TESTDIR/outputs
-gm_test "--hierarchy --match dashing --config 4444 -r $GM_INPUTS/dashing-correct-images" "$GM_OUTPUTS/dashing-compared-against-correct"
+# Compare generated image against an input image file with identical bytes.
+gm_test "--hierarchy --match dashing2 --config 4444 -r $GM_INPUTS/identical-bytes" "$GM_OUTPUTS/compared-against-identical-bytes"
-# In this case, dashing.png has different pixels, but dashing2.png differs only in PNG encoding (identical pixels)
-gm_test "--hierarchy --match dashing --config 4444 -r $GM_INPUTS/dashing-incorrect-images" "$GM_OUTPUTS/dashing-compared-against-incorrect"
+# Compare generated image against an input image file with identical pixels but different PNG encoding.
+gm_test "--hierarchy --match dashing2 --config 4444 -r $GM_INPUTS/identical-pixels" "$GM_OUTPUTS/compared-against-identical-pixels"
+
+# Compare generated image against an input image file with different pixels.
+gm_test "--hierarchy --match dashing2 --config 4444 -r $GM_INPUTS/different-pixels" "$GM_OUTPUTS/compared-against-different-pixels"
echo "All tests passed."