[mutter] tests/cogl: Migrate sparse pipeline test



commit 400cc8936421f84bf04af0608ff3b10355974cb2
Author: Jonas Ã…dahl <jadahl gmail com>
Date:   Thu Aug 4 20:08:40 2022 +0200

    tests/cogl: Migrate sparse pipeline test
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2555>

 cogl/tests/conform/meson.build                                | 1 -
 cogl/tests/conform/test-conform-main.c                        | 2 --
 cogl/tests/conform/test-declarations.h                        | 1 -
 src/tests/cogl/conform/meson.build                            | 1 +
 {cogl/tests => src/tests/cogl}/conform/test-sparse-pipeline.c | 8 +++++---
 5 files changed, 6 insertions(+), 7 deletions(-)
---
diff --git a/cogl/tests/conform/meson.build b/cogl/tests/conform/meson.build
index 40f0486023..27416c480a 100644
--- a/cogl/tests/conform/meson.build
+++ b/cogl/tests/conform/meson.build
@@ -1,6 +1,5 @@
 cogl_test_conformance_sources = [
   'test-conform-main.c',
-  'test-sparse-pipeline.c',
   'test-read-texture-formats.c',
   'test-write-texture-formats.c',
   'test-point-size.c',
diff --git a/cogl/tests/conform/test-conform-main.c b/cogl/tests/conform/test-conform-main.c
index af523c82fb..ada56fc95a 100644
--- a/cogl/tests/conform/test-conform-main.c
+++ b/cogl/tests/conform/test-conform-main.c
@@ -62,8 +62,6 @@ main (int argc, char **argv)
   UNPORTED_TEST (test_readpixels);
   ADD_TEST (test_layer_remove, 0, 0);
 
-  ADD_TEST (test_sparse_pipeline, 0, 0);
-
   ADD_TEST (test_npot_texture, 0, 0);
   UNPORTED_TEST (test_multitexture);
   UNPORTED_TEST (test_texture_mipmaps);
diff --git a/cogl/tests/conform/test-declarations.h b/cogl/tests/conform/test-declarations.h
index 123277e641..d6c0588b2a 100644
--- a/cogl/tests/conform/test-declarations.h
+++ b/cogl/tests/conform/test-declarations.h
@@ -6,7 +6,6 @@ void test_path_clip (void);
 void test_depth_test (void);
 void test_backface_culling (void);
 void test_layer_remove (void);
-void test_sparse_pipeline (void);
 void test_npot_texture (void);
 void test_texture_get_set_data (void);
 void test_read_texture_formats (void);
diff --git a/src/tests/cogl/conform/meson.build b/src/tests/cogl/conform/meson.build
index 92d2150949..940a8bb913 100644
--- a/src/tests/cogl/conform/meson.build
+++ b/src/tests/cogl/conform/meson.build
@@ -17,6 +17,7 @@ cogl_tests = [
   'test-offscreen',
   'test-journal',
   'test-primitive',
+  'test-sparse-pipeline',
 ]
 
 cogl_test_conformance_includes = [
diff --git a/cogl/tests/conform/test-sparse-pipeline.c b/src/tests/cogl/conform/test-sparse-pipeline.c
similarity index 92%
rename from cogl/tests/conform/test-sparse-pipeline.c
rename to src/tests/cogl/conform/test-sparse-pipeline.c
index 5e694d83cc..142d2ad2ce 100644
--- a/cogl/tests/conform/test-sparse-pipeline.c
+++ b/src/tests/cogl/conform/test-sparse-pipeline.c
@@ -1,8 +1,7 @@
 #include <cogl/cogl.h>
 #include <string.h>
 
-#include "test-declarations.h"
-#include "test-utils.h"
+#include "tests/cogl-test-utils.h"
 
 typedef struct _TestState
 {
@@ -43,7 +42,7 @@ test_sparse_layer_combine (TestState *state)
   cogl_object_unref (tex2);
 }
 
-void
+static void
 test_sparse_pipeline (void)
 {
   TestState state;
@@ -61,3 +60,6 @@ test_sparse_pipeline (void)
     g_print ("OK\n");
 }
 
+COGL_TEST_SUITE (
+  g_test_add_func ("/sparse-pipeline", test_sparse_pipeline);
+)


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