[gtk/wip/otte/for-master: 95/96] testsuite: Add render tests for all the empty nodes



commit 0a32305f01791d819158b305b9f294ca58ffd33c
Author: Benjamin Otte <otte redhat com>
Date:   Mon May 20 03:32:30 2019 +0200

    testsuite: Add render tests for all the empty nodes
    
    Test that rendering empty nodes succees. For a lot of nodes the
    resulting rendering isn't clearly defined, in those cases we overdraw
    those regions (sometimes the whole image) with black.

 testsuite/gsk/compare/empty-blend.node           |   1 +
 testsuite/gsk/compare/empty-blend.png            | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-blur.node            |  20 ++++++++++++++++++++
 testsuite/gsk/compare/empty-blur.png             | Bin 0 -> 167 bytes
 testsuite/gsk/compare/empty-border.node          |   1 +
 testsuite/gsk/compare/empty-border.png           | Bin 0 -> 169 bytes
 testsuite/gsk/compare/empty-clip.node            |   1 +
 testsuite/gsk/compare/empty-clip.png             | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-color-matrix.node    |   1 +
 testsuite/gsk/compare/empty-color-matrix.png     | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-color.node           |   1 +
 testsuite/gsk/compare/empty-color.png            | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-container.node       |   8 ++++++++
 testsuite/gsk/compare/empty-container.png        | Bin 0 -> 86 bytes
 testsuite/gsk/compare/empty-cross-fade.node      |   9 +++++++++
 testsuite/gsk/compare/empty-cross-fade.png       | Bin 0 -> 105 bytes
 testsuite/gsk/compare/empty-debug.node           |   1 +
 testsuite/gsk/compare/empty-debug.png            | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-inset-shadow.node    |   1 +
 testsuite/gsk/compare/empty-inset-shadow.png     | Bin 0 -> 164 bytes
 testsuite/gsk/compare/empty-linear-gradient.node |   1 +
 testsuite/gsk/compare/empty-linear-gradient.png  | Bin 0 -> 203 bytes
 testsuite/gsk/compare/empty-opacity.node         |   9 +++++++++
 testsuite/gsk/compare/empty-opacity.png          | Bin 0 -> 105 bytes
 testsuite/gsk/compare/empty-outset-shadow.node   |   1 +
 testsuite/gsk/compare/empty-outset-shadow.png    | Bin 0 -> 168 bytes
 testsuite/gsk/compare/empty-repeat.node          |   1 +
 testsuite/gsk/compare/empty-repeat.png           | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-rounded-clip.node    |   1 +
 testsuite/gsk/compare/empty-rounded-clip.png     | Bin 0 -> 153 bytes
 testsuite/gsk/compare/empty-shadow.node          |   1 +
 testsuite/gsk/compare/empty-shadow.png           | Bin 0 -> 181 bytes
 testsuite/gsk/compare/empty-text.node            |   1 +
 testsuite/gsk/compare/empty-text.png             | Bin 0 -> 405 bytes
 testsuite/gsk/compare/empty-texture.node         |  12 ++++++++++++
 testsuite/gsk/compare/empty-texture.png          | Bin 0 -> 197 bytes
 testsuite/gsk/compare/empty-transform.node       |   1 +
 testsuite/gsk/compare/empty-transform.png        | Bin 0 -> 153 bytes
 testsuite/gsk/meson.build                        |  19 +++++++++++++++++++
 39 files changed, 91 insertions(+)
---
diff --git a/testsuite/gsk/compare/empty-blend.node b/testsuite/gsk/compare/empty-blend.node
new file mode 100644
index 0000000000..291d805ff7
--- /dev/null
+++ b/testsuite/gsk/compare/empty-blend.node
@@ -0,0 +1 @@
+blend { }
diff --git a/testsuite/gsk/compare/empty-blend.png b/testsuite/gsk/compare/empty-blend.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-blend.png differ
diff --git a/testsuite/gsk/compare/empty-blur.node b/testsuite/gsk/compare/empty-blur.node
new file mode 100644
index 0000000000..a4a6298c09
--- /dev/null
+++ b/testsuite/gsk/compare/empty-blur.node
@@ -0,0 +1,20 @@
+blur { }
+
+/* The blur algorithm isn't specified, so
+   don't test it. */
+color {
+  bounds: -3 -3 50 6;
+  color: black;
+}
+color {
+  bounds: 47 -3 6 50;
+  color: black;
+}
+color {
+  bounds: 3 47 50 6;
+  color: black;
+}
+color {
+  bounds: -3 3 6 50;
+  color: black;
+}
diff --git a/testsuite/gsk/compare/empty-blur.png b/testsuite/gsk/compare/empty-blur.png
new file mode 100644
index 0000000000..313d6d8811
Binary files /dev/null and b/testsuite/gsk/compare/empty-blur.png differ
diff --git a/testsuite/gsk/compare/empty-border.node b/testsuite/gsk/compare/empty-border.node
new file mode 100644
index 0000000000..0a58c89c65
--- /dev/null
+++ b/testsuite/gsk/compare/empty-border.node
@@ -0,0 +1 @@
+border { }
diff --git a/testsuite/gsk/compare/empty-border.png b/testsuite/gsk/compare/empty-border.png
new file mode 100644
index 0000000000..5d3e0fdcb1
Binary files /dev/null and b/testsuite/gsk/compare/empty-border.png differ
diff --git a/testsuite/gsk/compare/empty-clip.node b/testsuite/gsk/compare/empty-clip.node
new file mode 100644
index 0000000000..c513eb6597
--- /dev/null
+++ b/testsuite/gsk/compare/empty-clip.node
@@ -0,0 +1 @@
+clip { }
diff --git a/testsuite/gsk/compare/empty-clip.png b/testsuite/gsk/compare/empty-clip.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-clip.png differ
diff --git a/testsuite/gsk/compare/empty-color-matrix.node b/testsuite/gsk/compare/empty-color-matrix.node
new file mode 100644
index 0000000000..c0fcc1cbd5
--- /dev/null
+++ b/testsuite/gsk/compare/empty-color-matrix.node
@@ -0,0 +1 @@
+color-matrix { }
diff --git a/testsuite/gsk/compare/empty-color-matrix.png b/testsuite/gsk/compare/empty-color-matrix.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-color-matrix.png differ
diff --git a/testsuite/gsk/compare/empty-color.node b/testsuite/gsk/compare/empty-color.node
new file mode 100644
index 0000000000..adaf509095
--- /dev/null
+++ b/testsuite/gsk/compare/empty-color.node
@@ -0,0 +1 @@
+color { }
diff --git a/testsuite/gsk/compare/empty-color.png b/testsuite/gsk/compare/empty-color.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-color.png differ
diff --git a/testsuite/gsk/compare/empty-container.node b/testsuite/gsk/compare/empty-container.node
new file mode 100644
index 0000000000..2ab6cf0ccb
--- /dev/null
+++ b/testsuite/gsk/compare/empty-container.node
@@ -0,0 +1,8 @@
+container { }
+
+/* We need to contain something because 0x0 nodes
+   cause NULL textures */
+color {
+  bounds: -1 -1 1 1;
+  color: transparent;
+}
diff --git a/testsuite/gsk/compare/empty-container.png b/testsuite/gsk/compare/empty-container.png
new file mode 100644
index 0000000000..7238a64657
Binary files /dev/null and b/testsuite/gsk/compare/empty-container.png differ
diff --git a/testsuite/gsk/compare/empty-cross-fade.node b/testsuite/gsk/compare/empty-cross-fade.node
new file mode 100644
index 0000000000..1b69ede5fc
--- /dev/null
+++ b/testsuite/gsk/compare/empty-cross-fade.node
@@ -0,0 +1,9 @@
+cross-fade { }
+
+/* This is not very useful as a test, because the
+   resulting color is undefined, because 0.5 * 255
+   can be rounded to either 127 or 128 by the renderers.
+   But at least we know they get the size right... */
+color {
+  color: black;
+}
diff --git a/testsuite/gsk/compare/empty-cross-fade.png b/testsuite/gsk/compare/empty-cross-fade.png
new file mode 100644
index 0000000000..68e443cac3
Binary files /dev/null and b/testsuite/gsk/compare/empty-cross-fade.png differ
diff --git a/testsuite/gsk/compare/empty-debug.node b/testsuite/gsk/compare/empty-debug.node
new file mode 100644
index 0000000000..088a305cf9
--- /dev/null
+++ b/testsuite/gsk/compare/empty-debug.node
@@ -0,0 +1 @@
+debug { }
diff --git a/testsuite/gsk/compare/empty-debug.png b/testsuite/gsk/compare/empty-debug.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-debug.png differ
diff --git a/testsuite/gsk/compare/empty-inset-shadow.node b/testsuite/gsk/compare/empty-inset-shadow.node
new file mode 100644
index 0000000000..5b84e7c8a5
--- /dev/null
+++ b/testsuite/gsk/compare/empty-inset-shadow.node
@@ -0,0 +1 @@
+inset-shadow { }
diff --git a/testsuite/gsk/compare/empty-inset-shadow.png b/testsuite/gsk/compare/empty-inset-shadow.png
new file mode 100644
index 0000000000..b159674785
Binary files /dev/null and b/testsuite/gsk/compare/empty-inset-shadow.png differ
diff --git a/testsuite/gsk/compare/empty-linear-gradient.node 
b/testsuite/gsk/compare/empty-linear-gradient.node
new file mode 100644
index 0000000000..ef6234b661
--- /dev/null
+++ b/testsuite/gsk/compare/empty-linear-gradient.node
@@ -0,0 +1 @@
+linear-gradient { }
diff --git a/testsuite/gsk/compare/empty-linear-gradient.png b/testsuite/gsk/compare/empty-linear-gradient.png
new file mode 100644
index 0000000000..f0e1db0e27
Binary files /dev/null and b/testsuite/gsk/compare/empty-linear-gradient.png differ
diff --git a/testsuite/gsk/compare/empty-opacity.node b/testsuite/gsk/compare/empty-opacity.node
new file mode 100644
index 0000000000..ef197ada17
--- /dev/null
+++ b/testsuite/gsk/compare/empty-opacity.node
@@ -0,0 +1,9 @@
+opacity { }
+
+/* This is not very useful as a test, because the
+   resulting color is undefined, because 0.5 * 255
+   can be rounded to either 127 or 128 by the renderers.
+   But at least we know they get the size right... */
+color {
+  color: black;
+}
diff --git a/testsuite/gsk/compare/empty-opacity.png b/testsuite/gsk/compare/empty-opacity.png
new file mode 100644
index 0000000000..68e443cac3
Binary files /dev/null and b/testsuite/gsk/compare/empty-opacity.png differ
diff --git a/testsuite/gsk/compare/empty-outset-shadow.node b/testsuite/gsk/compare/empty-outset-shadow.node
new file mode 100644
index 0000000000..87858be472
--- /dev/null
+++ b/testsuite/gsk/compare/empty-outset-shadow.node
@@ -0,0 +1 @@
+outset-shadow { }
diff --git a/testsuite/gsk/compare/empty-outset-shadow.png b/testsuite/gsk/compare/empty-outset-shadow.png
new file mode 100644
index 0000000000..3a5fd99bdd
Binary files /dev/null and b/testsuite/gsk/compare/empty-outset-shadow.png differ
diff --git a/testsuite/gsk/compare/empty-repeat.node b/testsuite/gsk/compare/empty-repeat.node
new file mode 100644
index 0000000000..9f82f0e3ac
--- /dev/null
+++ b/testsuite/gsk/compare/empty-repeat.node
@@ -0,0 +1 @@
+repeat { }
diff --git a/testsuite/gsk/compare/empty-repeat.png b/testsuite/gsk/compare/empty-repeat.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-repeat.png differ
diff --git a/testsuite/gsk/compare/empty-rounded-clip.node b/testsuite/gsk/compare/empty-rounded-clip.node
new file mode 100644
index 0000000000..28373aa45f
--- /dev/null
+++ b/testsuite/gsk/compare/empty-rounded-clip.node
@@ -0,0 +1 @@
+rounded-clip { }
diff --git a/testsuite/gsk/compare/empty-rounded-clip.png b/testsuite/gsk/compare/empty-rounded-clip.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-rounded-clip.png differ
diff --git a/testsuite/gsk/compare/empty-shadow.node b/testsuite/gsk/compare/empty-shadow.node
new file mode 100644
index 0000000000..3f4879359d
--- /dev/null
+++ b/testsuite/gsk/compare/empty-shadow.node
@@ -0,0 +1 @@
+shadow { }
diff --git a/testsuite/gsk/compare/empty-shadow.png b/testsuite/gsk/compare/empty-shadow.png
new file mode 100644
index 0000000000..47617ce64c
Binary files /dev/null and b/testsuite/gsk/compare/empty-shadow.png differ
diff --git a/testsuite/gsk/compare/empty-text.node b/testsuite/gsk/compare/empty-text.node
new file mode 100644
index 0000000000..5964c4e7d1
--- /dev/null
+++ b/testsuite/gsk/compare/empty-text.node
@@ -0,0 +1 @@
+text { }
diff --git a/testsuite/gsk/compare/empty-text.png b/testsuite/gsk/compare/empty-text.png
new file mode 100644
index 0000000000..cd7cd8af8d
Binary files /dev/null and b/testsuite/gsk/compare/empty-text.png differ
diff --git a/testsuite/gsk/compare/empty-texture.node b/testsuite/gsk/compare/empty-texture.node
new file mode 100644
index 0000000000..ba8d2d4fb8
--- /dev/null
+++ b/testsuite/gsk/compare/empty-texture.node
@@ -0,0 +1,12 @@
+texture { }
+
+/* The bilinear filtering code can differ
+   between implementations, so cover it */
+color {
+  bounds: 21 0 10 50;
+  color: black;
+}
+color {
+  bounds: 0 21 50 10;
+  color: black;
+}
diff --git a/testsuite/gsk/compare/empty-texture.png b/testsuite/gsk/compare/empty-texture.png
new file mode 100644
index 0000000000..bb5a60636f
Binary files /dev/null and b/testsuite/gsk/compare/empty-texture.png differ
diff --git a/testsuite/gsk/compare/empty-transform.node b/testsuite/gsk/compare/empty-transform.node
new file mode 100644
index 0000000000..4833ddb193
--- /dev/null
+++ b/testsuite/gsk/compare/empty-transform.node
@@ -0,0 +1 @@
+transform { }
diff --git a/testsuite/gsk/compare/empty-transform.png b/testsuite/gsk/compare/empty-transform.png
new file mode 100644
index 0000000000..3a032a391b
Binary files /dev/null and b/testsuite/gsk/compare/empty-transform.png differ
diff --git a/testsuite/gsk/meson.build b/testsuite/gsk/meson.build
index e2e0328284..cecc0ebed0 100644
--- a/testsuite/gsk/meson.build
+++ b/testsuite/gsk/meson.build
@@ -32,6 +32,25 @@ compare_render_tests = [
   'clipped_rounded_clip',
   'color-blur0',
   'cross-fade-in-opacity',
+  'empty-blend',
+  'empty-blur',
+  'empty-border',
+  'empty-clip',
+  'empty-color',
+  'empty-color-matrix',
+  'empty-container',
+  'empty-cross-fade',
+  'empty-debug',
+  'empty-inset-shadow',
+  'empty-linear-gradient',
+  'empty-opacity',
+  'empty-outset-shadow',
+  'empty-repeat',
+  'empty-rounded-clip',
+  'empty-shadow',
+  'empty-text',
+  'empty-texture',
+  'empty-transform',
   'opacity_clip',
   'outset_shadow_offset_both',
   'outset_shadow_offset_x',


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]