[mutter] tests/cogl: Migrate pipeline user matrix test



commit 63af78d049c2985f1b6deedcc6897f315e194fc8
Author: Jonas Ã…dahl <jadahl gmail com>
Date:   Thu Aug 4 19:41:03 2022 +0200

    tests/cogl: Migrate pipeline user matrix 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                           | 1 -
 cogl/tests/conform/test-declarations.h                           | 1 -
 src/tests/cogl/conform/meson.build                               | 1 +
 .../tests => src/tests/cogl}/conform/test-pipeline-user-matrix.c | 9 ++++++---
 5 files changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/cogl/tests/conform/meson.build b/cogl/tests/conform/meson.build
index 2eb5251e39..08f685d66f 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-pipeline-user-matrix.c',
   'test-pipeline-uniforms.c',
   'test-pixel-buffer.c',
   'test-premult.c',
diff --git a/cogl/tests/conform/test-conform-main.c b/cogl/tests/conform/test-conform-main.c
index 2371b9786d..6a7ec44f46 100644
--- a/cogl/tests/conform/test-conform-main.c
+++ b/cogl/tests/conform/test-conform-main.c
@@ -59,7 +59,6 @@ main (int argc, char **argv)
   UNPORTED_TEST (test_object);
   UNPORTED_TEST (test_fixed);
   UNPORTED_TEST (test_materials);
-  ADD_TEST (test_pipeline_user_matrix, 0, 0);
   ADD_TEST (test_premult, 0, 0);
   UNPORTED_TEST (test_readpixels);
   ADD_TEST (test_layer_remove, 0, 0);
diff --git a/cogl/tests/conform/test-declarations.h b/cogl/tests/conform/test-declarations.h
index 952919b37a..54006afa1b 100644
--- a/cogl/tests/conform/test-declarations.h
+++ b/cogl/tests/conform/test-declarations.h
@@ -1,7 +1,6 @@
 #ifndef COGL_TEST_DECLARATIONS_H
 #define COGL_TEST_DECLARATIONS_H
 
-void test_pipeline_user_matrix (void);
 void test_premult (void);
 void test_path (void);
 void test_path_clip (void);
diff --git a/src/tests/cogl/conform/meson.build b/src/tests/cogl/conform/meson.build
index ce120451b8..a6d365d90f 100644
--- a/src/tests/cogl/conform/meson.build
+++ b/src/tests/cogl/conform/meson.build
@@ -6,6 +6,7 @@ cogl_tests = [
   'test-color-hsl',
   'test-backface-culling',
   'test-just-vertex-shader',
+  'test-pipeline-user-matrix',
 ]
 
 cogl_test_conformance_includes = [
diff --git a/cogl/tests/conform/test-pipeline-user-matrix.c 
b/src/tests/cogl/conform/test-pipeline-user-matrix.c
similarity index 97%
rename from cogl/tests/conform/test-pipeline-user-matrix.c
rename to src/tests/cogl/conform/test-pipeline-user-matrix.c
index ac538717ee..9137d78645 100644
--- a/cogl/tests/conform/test-pipeline-user-matrix.c
+++ b/src/tests/cogl/conform/test-pipeline-user-matrix.c
@@ -2,8 +2,7 @@
 
 #include <string.h>
 
-#include "test-declarations.h"
-#include "test-utils.h"
+#include "tests/cogl-test-utils.h"
 
 typedef struct _TestState
 {
@@ -128,7 +127,7 @@ paint (TestState *state)
   cogl_object_unref (pipeline);
 }
 
-void
+static void
 test_pipeline_user_matrix (void)
 {
   TestState state;
@@ -142,3 +141,7 @@ test_pipeline_user_matrix (void)
   if (cogl_test_verbose ())
     g_print ("OK\n");
 }
+
+COGL_TEST_SUITE (
+  g_test_add_func ("/pipeline/user-matrix", test_pipeline_user_matrix);
+)


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