Work around #1014417 in Meson
authorSimon McVittie <smcv@debian.org>
Mon, 8 Aug 2022 15:50:40 +0000 (16:50 +0100)
committerSimon McVittie <smcv@debian.org>
Mon, 8 Aug 2022 18:22:54 +0000 (19:22 +0100)
Forwarded: not-needed, Meson should be fixed instead

Gbp-Pq: Name Work-around-1014417-in-Meson.patch

13 files changed:
testsuite/a11y/meson.build
testsuite/css/change/meson.build
testsuite/css/meson.build
testsuite/css/nodes/meson.build
testsuite/css/parser/meson.build
testsuite/css/style/meson.build
testsuite/gdk/meson.build
testsuite/gsk/meson.build
testsuite/gtk/meson.build
testsuite/meson.build
testsuite/reftests/gtk-reftest.c
testsuite/reftests/meson.build
testsuite/tools/meson.build

index 4f50d3a6069455e211dec0ba50b594327c830aaa..a0344f54e1a6647a9a8aa0240980c2d2fc327761 100644 (file)
@@ -84,7 +84,7 @@ foreach t : tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     timeout: test_timeout,
     env: test_env,
     suite: ['a11y'] + test_extra_suites,
index 9409f483c1799f45bb49ee179752cd2a1ca5b63f..c88ea618d916fb8514e7259431bf9f05d4b07179 100644 (file)
@@ -22,7 +22,7 @@ test_change = executable(
 
 test('change', test_change,
   args: [ '--tap', '-k' ],
-  protocol: 'tap',
+  protocol: tap_test_protocol,
   env: changetest_env,
   suite: 'css',
 )
index 20c031410dc645cc8f3b765cad8dccdecb9ff040..dcc92406357b6d4adb668c84c87e2e6041945261 100644 (file)
@@ -25,7 +25,7 @@ test_api = executable('api', 'api.c',
 
 test('api', test_api,
   args: ['--tap', '-k' ],
-  protocol: 'tap',
+  protocol: tap_test_protocol,
   env: csstest_env,
   suite: 'css',
 )
@@ -40,7 +40,7 @@ test_data = executable('data', 'data.c',
 
 test('data', test_data,
   args: ['--tap', '-k' ],
-  protocol: 'tap',
+  protocol: tap_test_protocol,
   env: csstest_env,
   suite: 'css',
 )
@@ -54,7 +54,7 @@ transition = executable('transition', 'transition.c',
 
 test('transition', transition,
      args: [ '--tap', '-k' ],
-     protocol: 'tap',
+     protocol: tap_test_protocol,
      env: csstest_env,
      suite: 'css'
 )
index eb619cf29ce0c9c6775a61cc5d1ac2a6e4afcf53..3c80ba2c92baf757cd580cba767d050b3fa94530 100644 (file)
@@ -17,7 +17,7 @@ test_nodes = executable('test-css-nodes', 'test-css-nodes.c', '../../testutils.c
                         dependencies: libgtk_dep)
 test('nodes', test_nodes,
   args: [ '--tap', '-k' ],
-  protocol: 'tap',
+  protocol: tap_test_protocol,
   env: nodetest_env,
   suite: 'css',
 )
index d0fdd0d9a98037377fcba880877dd7ec5dbf2bd7..3029f53d9afe0a305e11181768dc4b475b9600a6 100644 (file)
@@ -529,7 +529,7 @@ foreach testname : test_data
                  '-k',
                  join_paths(meson.current_source_dir(), testname),
                ],
-         protocol: 'tap',
+         protocol: tap_test_protocol,
          env: [
                 'G_TEST_SRCDIR=@0@'.format(meson.current_source_dir()),
                 'G_TEST_BUILDDIR=@0@'.format(meson.current_build_dir())
index 9dc0f4c34c4daec06cd235208e43ea78d4d1c188..c543a1602f2680554d4257f9f8bdb2c4b755a7ed 100644 (file)
@@ -28,7 +28,7 @@ test_style = executable(
 )
 test('style', test_style,
   args: [ '--tap', '-k' ],
-  protocol: 'tap',
+  protocol: tap_test_protocol,
   env: styletest_env,
   suite: 'css',
 )
index 14b2c857e18fbe462cfac75ac81b2a8e9dd57c99..533cd9b503e7ef4cdcb04a5f0f399a06952b044f 100644 (file)
@@ -41,7 +41,7 @@ foreach t : tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     is_parallel: t.get('parallel', false),
     env: [
       'G_TEST_SRCDIR=@0@'.format(meson.current_source_dir()),
@@ -66,7 +66,7 @@ foreach t : internal_tests
 
   test(t, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     env: [
       'G_TEST_SRCDIR=@0@'.format(meson.current_source_dir()),
       'G_TEST_BUILDDIR=@0@'.format(meson.current_build_dir()),
index 8c3ff1fddfb9bf086b2b73f30722b68e595e3206..9c60dbdc5268998982791a1533a899670e3ed778 100644 (file)
@@ -233,7 +233,7 @@ foreach t : tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     env: [
       'GSK_RENDERER=cairo',
       'GTK_A11Y=test',
@@ -265,7 +265,7 @@ foreach t : internal_tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     env: [
       'GSK_RENDERER=cairo',
       'GTK_A11Y=test',
index 3324664cac6ab382c2c987eec32d08eaf42b8fd9..de24177b521391f3ba48aedd6223171db71c1c8b 100644 (file)
@@ -184,7 +184,7 @@ foreach t : tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     timeout: test_timeout,
     env: test_env,
     suite: ['gtk'] + test_extra_suites,
@@ -217,7 +217,7 @@ foreach t : internal_tests
 
   test(test_name, test_exe,
     args: [ '--tap', '-k' ],
-    protocol: 'tap',
+    protocol: tap_test_protocol,
     timeout: test_timeout,
     env: test_env,
     suite: ['gtk'] + test_extra_suites,
@@ -235,7 +235,7 @@ if add_languages('cpp', required: false, native: false)
   )
   test('c++ keywords', test_exe,
     args: [ '--tap', '-k' ],
-    #protocol: 'tap',
+    #protocol: tap_test_protocol,
     env: test_env,
     suite: 'gtk',
   )
index 97344f3062e026e583ff1f31756287d7d7b26c96..05d6a579260ce45cbc4e28b8a6338af97656e005 100644 (file)
@@ -2,6 +2,13 @@ gtk_libexecdir = join_paths(gtk_prefix, get_option('libexecdir'))
 installed_test_bindir = join_paths(gtk_libexecdir, 'installed-tests', 'gtk-4.0')
 installed_test_datadir = join_paths(gtk_datadir, 'installed-tests', 'gtk-4.0')
 
+if meson.version() == '0.63.0'
+    # Work around https://github.com/mesonbuild/meson/issues/10577
+    tap_test_protocol = 'exitcode'
+else
+    tap_test_protocol = 'tap'
+endif
+
 common_env = [
   'GIO_USE_VOLUME_MONITOR=unix',
   'GSETTINGS_BACKEND=memory',
index aa4d3c7efa3254af7517cee5759583337a900a2d..3706baffce9ddf24014d1de61fc6126283cd1373 100644 (file)
@@ -602,9 +602,5 @@ main (int argc, char **argv)
 
   result = g_test_run ();
 
-  if (using_tap)
-    return 0;
-
   return result;
 }
-
index 2c6e10429baad154ad8b1115ae3af7a23c249d30..33e307a7f2c9ae4b0665c0f1e892592ee7918cbe 100644 (file)
@@ -607,7 +607,7 @@ foreach testname : testdata
         '-o', join_paths(meson.current_build_dir(), 'output'),
         join_paths(meson.current_source_dir(), testname),
       ],
-      protocol: 'tap',
+      protocol: tap_test_protocol,
       env: reftest_env,
       suite: 'reftest',
       should_fail: xfails.contains(testname),
index 582bce6fb808a69f39fb76c9ad6f2523ac0c26b5..4b1279787a0ce6eaca5bbef3cb99de44f714c979 100644 (file)
@@ -21,7 +21,7 @@ if bash.found()
     test(t, bash,
       args: t,
       workdir: meson.current_build_dir(),
-      protocol: 'tap',
+      protocol: tap_test_protocol,
       env: [
         'TEST_RESULT_DIR=@0@'.format(join_paths(meson.current_build_dir(), 'output')),
         'G_TEST_SRCDIR=@0@'.format(meson.current_source_dir()),