From 5f706c73fd91f7bf949972e118d3bb7e36744c0c Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Fri, 30 Sep 2022 14:24:05 -0400 Subject: [PATCH] testsuite: Compare textures properly When compoaring textures, we now need to look at the colorspace as well. --- testsuite/gdk/contentserializer.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/testsuite/gdk/contentserializer.c b/testsuite/gdk/contentserializer.c index a807951707..bffaf63329 100644 --- a/testsuite/gdk/contentserializer.c +++ b/testsuite/gdk/contentserializer.c @@ -42,9 +42,13 @@ textures_equal (GdkTexture *t1, GdkTexture *t2) if (width != gdk_texture_get_width (t2)) return FALSE; + if (height != gdk_texture_get_height (t2)) return FALSE; + if (!gdk_color_state_equal (gdk_texture_get_color_state (t1), gdk_texture_get_color_state (t2))) + return FALSE; + d1 = g_malloc (width * height * 4); d2 = g_malloc (width * height * 4);