summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2016-12-28 16:38:00 +0100
committerBastien Nocera <hadess@hadess.net>2016-12-28 16:45:31 +0100
commit39a31870177bb06162c3cd1a8d0dbb3571ee3c0b (patch)
tree1c23b5461dd33c00f947f29ab908630cf3a91c54 /tests
parent1fb2e914cee72ef2401ebb2679fd85c37ae92c69 (diff)
downloadgdk-pixbuf-39a31870177bb06162c3cd1a8d0dbb3571ee3c0b.tar.gz
tests: Fill the default pixbuf with the placeholder colour
Ideally, we should only be comparing data that the loader told us it updated, and this is kind of what we're doing, as long as we don't have a legitimate image that uses the exact same filler colour. Unlikely though. https://bugzilla.gnome.org/show_bug.cgi?id=696331
Diffstat (limited to 'tests')
-rw-r--r--tests/pixbuf-reftest.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/pixbuf-reftest.c b/tests/pixbuf-reftest.c
index 25e878374..fd5414618 100644
--- a/tests/pixbuf-reftest.c
+++ b/tests/pixbuf-reftest.c
@@ -25,6 +25,9 @@
#include "test-common.h"
+/* As defined in gdk-pixbuf-private.h */
+#define DEFAULT_FILL_COLOR 0x979899ff
+
static void
loader_size_prepared (GdkPixbufLoader *loader,
int w,
@@ -35,6 +38,8 @@ loader_size_prepared (GdkPixbufLoader *loader,
*pixbuf = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, w, h);
g_assert (*pixbuf != NULL);
+ /* likely!! */
+ gdk_pixbuf_fill (*pixbuf, DEFAULT_FILL_COLOR);
}
static void