From cd4dbd67a25bf7dcd9054dfee7983a7d9672a140 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Tue, 18 Oct 2022 23:22:15 -0400 Subject: [PATCH] testsuite: Skip known-broken tests The tiff pixbuf tests fail because of known issues with the pixbuf tiff loader. Skip them. Fixes: #4615 --- testsuite/gdk/memorytexture.c | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/testsuite/gdk/memorytexture.c b/testsuite/gdk/memorytexture.c index 1262800730..5b0b146c4a 100644 --- a/testsuite/gdk/memorytexture.c +++ b/testsuite/gdk/memorytexture.c @@ -114,7 +114,7 @@ encode (GdkMemoryFormat format, return GSIZE_TO_POINTER (method * GDK_MEMORY_N_FORMATS + format); } -static void +static gboolean decode (gconstpointer data, GdkMemoryFormat *format, TextureMethod *method) @@ -125,8 +125,16 @@ decode (gconstpointer data, value /= GDK_MEMORY_N_FORMATS; *method = value; + + if (*method == TEXTURE_METHOD_TIFF_PIXBUF) + { + g_test_skip ("the pixbuf tiff loader is broken (gdk-pixbuf#100)"); + return FALSE; + } + + return TRUE; } - + static void texture_builder_init (TextureBuilder *builder, GdkMemoryFormat format, @@ -537,7 +545,8 @@ test_download_1x1 (gconstpointer data) GdkTexture *expected, *test; gsize i; - decode (data, &format, &method); + if (!decode (data, &format, &method)) + return; for (i = 0; i < N; i++) { @@ -562,7 +571,8 @@ test_download_4x4 (gconstpointer data) GdkTexture *expected, *test; gsize i; - decode (data, &format, &method); + if (!decode (data, &format, &method)) + return; for (i = 0; i < N; i++) { @@ -588,7 +598,8 @@ test_download_192x192 (gconstpointer data) GdkTexture *expected, *test; GdkRGBA color; - decode (data, &format, &method); + if (!decode (data, &format, &method)) + return; create_random_color (&color); expected = create_texture (GDK_MEMORY_DEFAULT, TEXTURE_METHOD_LOCAL, 192, 192, &color); -- 2.30.2