[gtk/fix-pixbuf-tiff-tests: 2/2] testsuite: Skip known-broken tests
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/fix-pixbuf-tiff-tests: 2/2] testsuite: Skip known-broken tests
- Date: Wed, 19 Oct 2022 03:23:25 +0000 (UTC)
commit cd4dbd67a25bf7dcd9054dfee7983a7d9672a140
Author: Matthias Clasen <mclasen redhat com>
Date: Tue Oct 18 23:22:15 2022 -0400
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);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]