2020-10-31 00:14:17 +00:00
|
|
|
changetest_env = environment()
|
2020-11-07 12:50:11 +00:00
|
|
|
changetest_env.set('GTK_A11Y', 'test')
|
2020-10-31 00:14:17 +00:00
|
|
|
changetest_env.set('GSK_RENDERER', 'cairo')
|
|
|
|
changetest_env.set('G_TEST_SRCDIR', meson.current_source_dir())
|
|
|
|
changetest_env.set('G_TEST_BUILDDIR', meson.current_build_dir())
|
|
|
|
changetest_env.set('GIO_USE_VFS', 'local')
|
|
|
|
changetest_env.set('GSETTINGS_BACKEND', 'memory')
|
|
|
|
changetest_env.set('G_ENABLE_DIAGNOSTIC', '0')
|
|
|
|
|
2020-01-17 01:02:55 +00:00
|
|
|
testexecdir = join_paths(installed_test_bindir, 'css', 'change')
|
|
|
|
testdatadir = join_paths(installed_test_datadir, 'css')
|
|
|
|
|
|
|
|
test_change = executable(
|
|
|
|
'test-css-change',
|
|
|
|
'test-css-change.c',
|
2021-01-22 04:57:24 +00:00
|
|
|
'../../testutils.c',
|
2020-03-06 17:16:54 +00:00
|
|
|
c_args: common_cflags,
|
2020-01-17 01:02:55 +00:00
|
|
|
dependencies: libgtk_dep,
|
|
|
|
install: get_option('install-tests'),
|
|
|
|
install_dir: testexecdir,
|
|
|
|
)
|
2020-10-09 17:17:04 +00:00
|
|
|
|
2020-01-17 01:02:55 +00:00
|
|
|
test('change', test_change,
|
2020-10-09 17:17:04 +00:00
|
|
|
args: [ '--tap', '-k' ],
|
|
|
|
protocol: 'tap',
|
2020-10-31 00:14:17 +00:00
|
|
|
env: changetest_env,
|
2020-10-09 17:17:04 +00:00
|
|
|
suite: 'css',
|
|
|
|
)
|
2020-01-17 01:02:55 +00:00
|
|
|
|
|
|
|
test_data = [
|
2020-01-17 01:04:00 +00:00
|
|
|
'test1.css', 'test1.ui', 'test1.nodes',
|
|
|
|
'test2.css', 'test2.ui', 'test2.nodes',
|
|
|
|
'test3.css', 'test3.ui', 'test3.nodes',
|
|
|
|
'test4.css', 'test4.ui', 'test4.nodes',
|
2020-01-17 01:02:55 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
if get_option('install-tests')
|
|
|
|
conf = configuration_data()
|
|
|
|
conf.set('libexecdir', gtk_libexecdir)
|
|
|
|
configure_file(input: 'change.test.in',
|
|
|
|
output: 'change.test',
|
|
|
|
configuration: conf,
|
|
|
|
install_dir: testdatadir)
|
|
|
|
|
|
|
|
install_data(test_data, install_dir: testexecdir)
|
|
|
|
|
|
|
|
endif
|