2017-10-18 02:41:57 +00:00
|
|
|
testexecdir = join_paths(installed_test_bindir, 'tools')
|
|
|
|
testdatadir = join_paths(installed_test_datadir, 'tools')
|
|
|
|
|
2017-03-22 13:39:14 +00:00
|
|
|
bash = find_program('bash', required : false)
|
|
|
|
if bash.found()
|
|
|
|
test_env = environment()
|
|
|
|
|
2020-11-01 19:47:02 +00:00
|
|
|
foreach t : ['simplify', 'simplify-3to4', 'validate', 'settings']
|
2019-03-29 13:59:58 +00:00
|
|
|
if get_option('install-tests')
|
|
|
|
configure_file(output: t,
|
2020-12-15 12:31:38 +00:00
|
|
|
input: '@0@.in'.format(t),
|
|
|
|
copy: true,
|
|
|
|
install_dir: testexecdir,
|
|
|
|
)
|
2019-03-29 13:59:58 +00:00
|
|
|
else
|
|
|
|
configure_file(output: t,
|
2020-12-15 12:31:38 +00:00
|
|
|
input: '@0@.in'.format(t),
|
|
|
|
copy: true,
|
|
|
|
)
|
2019-03-29 13:59:58 +00:00
|
|
|
endif
|
2017-10-17 18:50:05 +00:00
|
|
|
test(t, bash,
|
2020-12-15 12:31:38 +00:00
|
|
|
args: t,
|
|
|
|
workdir: meson.current_build_dir(),
|
|
|
|
protocol: 'tap',
|
|
|
|
env: [
|
2021-07-28 17:21:03 +00:00
|
|
|
'TEST_RESULT_DIR=@0@'.format(join_paths(meson.current_build_dir(), 'output')),
|
2020-12-15 12:31:38 +00:00
|
|
|
'G_TEST_SRCDIR=@0@'.format(meson.current_source_dir()),
|
|
|
|
'G_TEST_BUILDDIR=@0@'.format(meson.current_build_dir()),
|
|
|
|
'GTK_A11Y=test',
|
|
|
|
'GTK_BUILDER_TOOL=@0@'.format(get_variable('gtk4_builder_tool').full_path()),
|
|
|
|
'GTK_QUERY_SETTINGS=@0@'.format(get_variable('gtk4_query_settings').full_path())
|
|
|
|
],
|
|
|
|
suite: 'tools',
|
|
|
|
)
|
2017-03-22 13:39:14 +00:00
|
|
|
endforeach
|
2017-10-18 02:41:57 +00:00
|
|
|
endif
|
2017-03-22 13:39:14 +00:00
|
|
|
|
2017-10-18 02:41:57 +00:00
|
|
|
if get_option('install-tests')
|
|
|
|
foreach t : ['simplify', 'settings']
|
|
|
|
test_conf = configuration_data()
|
|
|
|
test_conf.set('testexecdir', testexecdir)
|
|
|
|
test_conf.set('test', t)
|
|
|
|
configure_file(output: '@0@.test'.format(t),
|
2020-12-15 12:31:38 +00:00
|
|
|
input: 'tools.test.in',
|
|
|
|
configuration: test_conf,
|
|
|
|
install_dir: testdatadir,
|
|
|
|
)
|
2017-10-18 02:41:57 +00:00
|
|
|
endforeach
|
2017-03-22 13:39:14 +00:00
|
|
|
|
2017-10-18 02:41:57 +00:00
|
|
|
install_subdir('simplify-data', install_dir: testexecdir)
|
2019-05-05 15:23:59 +00:00
|
|
|
install_subdir('simplify-data-3to4', install_dir: testexecdir)
|
2020-11-01 19:47:02 +00:00
|
|
|
install_subdir('validate-data', install_dir: testexecdir)
|
2017-10-18 02:41:57 +00:00
|
|
|
endif
|