[gtk+] Make css parser tests run



commit 37f1d180c38b6750ca5584be9a026b3303dc7602
Author: Matthias Clasen <mclasen redhat com>
Date:   Thu Oct 12 15:58:05 2017 +0800

    Make css parser tests run
    
    We need to set G_TEST_SRCDIR and friends for this to do anything.
    Setting it reveals that a bunch of the tests are broken.

 testsuite/css/parser/meson.build |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/testsuite/css/parser/meson.build b/testsuite/css/parser/meson.build
index 3ea4bf0..7bb8df9 100644
--- a/testsuite/css/parser/meson.build
+++ b/testsuite/css/parser/meson.build
@@ -1,10 +1,16 @@
+test_env = environment()
+test_env.set('G_TEST_SRCDIR', meson.current_source_dir())
+test_env.set('G_TEST_BUILDDIR', meson.current_build_dir())
+test_env.set('GSETTINGS_BACKEND', 'memory')
+test_env.set('G_ENABLE_DIAGNOSTIC', '0')
+
 testexecdir = join_paths(installed_test_bindir, 'css', 'parser')
 
 test_parser = executable('test-css-parser', 'test-css-parser.c',
-                        install: get_option('install-tests'),
-                        install_dir: testexecdir,
+                         install: get_option('install-tests'),
+                         install_dir: testexecdir,
                          dependencies: libgtk_dep)
-test('css-parser', test_parser, suite: 'css')
+test('css-parser', test_parser, suite: 'css', env: test_env)
 
 test_data = [
   'animation-crash-3.12.css',


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