From 629c23b2290c35954d2f499c247d8741f127aef1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Thu, 4 Aug 2022 22:01:03 +0200 Subject: [PATCH] tests/cogl: Migrate npot texture test Part-of: --- 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-npot-texture.c | 8 +++++--- 5 files changed, 6 insertions(+), 6 deletions(-) rename {cogl/tests => src/tests/cogl}/conform/test-npot-texture.c (97%) diff --git a/cogl/tests/conform/meson.build b/cogl/tests/conform/meson.build index f105f4128..b9abea649 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-npot-texture.c', 'test-alpha-textures.c', 'test-texture-get-set-data.c', 'test-framebuffer-get-bits.c', diff --git a/cogl/tests/conform/test-conform-main.c b/cogl/tests/conform/test-conform-main.c index f5960a304..1ef3bdc96 100644 --- a/cogl/tests/conform/test-conform-main.c +++ b/cogl/tests/conform/test-conform-main.c @@ -61,7 +61,6 @@ main (int argc, char **argv) UNPORTED_TEST (test_materials); UNPORTED_TEST (test_readpixels); - ADD_TEST (test_npot_texture, 0, 0); UNPORTED_TEST (test_multitexture); UNPORTED_TEST (test_texture_mipmaps); UNPORTED_TEST (test_texture_rectangle); diff --git a/cogl/tests/conform/test-declarations.h b/cogl/tests/conform/test-declarations.h index b0323fb00..2396f08c3 100644 --- a/cogl/tests/conform/test-declarations.h +++ b/cogl/tests/conform/test-declarations.h @@ -5,7 +5,6 @@ void test_path (void); void test_path_clip (void); void test_depth_test (void); void test_backface_culling (void); -void test_npot_texture (void); void test_texture_get_set_data (void); void test_alpha_textures (void); void test_framebuffer_get_bits (void); diff --git a/src/tests/cogl/conform/meson.build b/src/tests/cogl/conform/meson.build index de4f56f05..b9529278e 100644 --- a/src/tests/cogl/conform/meson.build +++ b/src/tests/cogl/conform/meson.build @@ -28,6 +28,7 @@ cogl_tests = [ [ 'test-layer-remove', [] ], [ 'test-alpha-test', [] ], [ 'test-map-buffer-range', [] ], + [ 'test-npot-texture', [] ], ] cogl_test_conformance_includes = [ diff --git a/cogl/tests/conform/test-npot-texture.c b/src/tests/cogl/conform/test-npot-texture.c similarity index 97% rename from cogl/tests/conform/test-npot-texture.c rename to src/tests/cogl/conform/test-npot-texture.c index 551f72b7b..ce5d3e29b 100644 --- a/cogl/tests/conform/test-npot-texture.c +++ b/src/tests/cogl/conform/test-npot-texture.c @@ -2,8 +2,7 @@ #include -#include "test-declarations.h" -#include "test-utils.h" +#include "tests/cogl-test-utils.h" /* Non-power-of-two sized texture that should cause slicing */ #define TEXTURE_SIZE 384 @@ -142,7 +141,7 @@ paint (void) cogl_object_unref (texture); } -void +static void test_npot_texture (void) { cogl_framebuffer_orthographic (test_fb, @@ -159,3 +158,6 @@ test_npot_texture (void) g_print ("OK\n"); } +COGL_TEST_SUITE ( + g_test_add_func ("/npot-texture", test_npot_texture); +)