1 common_gio_tests_deps = [
9 '-DG_LOG_DOMAIN="GLib-GIO"',
10 '-DGLIB_MKENUMS="@0@"'.format(glib_mkenums),
11 '-DGLIB_COMPILE_SCHEMAS="@0@"'.format(glib_compile_schemas.full_path()),
15 # workaround for https://github.com/mesonbuild/meson/issues/6880
16 if build_machine.system() == 'linux'
17 libutil_name = 'libutil'
18 libutil = run_command('sh', '-c',
19 '''ldconfig -p | grep -o "[[:space:]]@0@\.so\(\.[0-9]\+\)\?\b"'''
20 .format(libutil_name)).stdout().strip().split('\n')
22 if libutil.length() > 0
23 message('Found libutil as @0@'.format(libutil[0]))
24 test_c_args += '-DLIBUTIL_SONAME="@0@"'.format(libutil[0])
26 warning('libutil not found')
27 endif # libutil.length() > 0
28 endif # build_machine.system() == 'linux'
30 if host_machine.system() == 'windows'
31 common_gio_tests_deps += [iphlpapi_dep, winsock2, cc.find_library ('secur32')]
34 subdir('gdbus-object-manager-example')
36 gengiotypefuncs_prog = find_program('gengiotypefuncs.py')
37 giotypefuncs_inc = custom_target(
39 output : 'giotypefuncs.inc',
40 input : gio_headers + [gioenumtypes_h] + gobject_install_headers,
41 command: [gengiotypefuncs_prog, '@OUTPUT@', '@INPUT@'])
43 # Test programs buildable on all platforms
46 'async-close-output-stream' : {},
47 'async-splice-output-stream' : {},
48 'buffered-input-stream' : {},
49 'buffered-output-stream' : {},
53 'converter-stream' : {},
55 'data-input-stream' : {},
56 'data-output-stream' : {},
57 'defaultvalue' : {'extra_sources' : [giotypefuncs_inc]},
58 'fileattributematcher' : {},
59 'filter-streams' : {},
65 'gdbus-addresses' : {},
69 'memory-input-stream' : {},
70 'memory-monitor' : {},
71 'memory-output-stream' : {},
72 'mount-operation' : {},
73 'network-address' : {'extra_sources': ['mock-resolver.c']},
74 'network-monitor' : {},
75 'network-monitor-race' : {},
77 'pollable' : {'dependencies' : [libdl_dep]},
78 'power-profile-monitor' : {},
81 'simple-async-result' : {},
85 'socket-listener' : {},
86 'socket-service' : {},
92 'testfilemonitor' : {'suite' : ['slow', 'flaky']},
93 'thumbnail-verification' : {},
94 'tls-certificate' : {'extra_sources' : ['gtesttlsbackend.c']},
95 'tls-interaction' : {'extra_sources' : ['gtesttlsbackend.c']},
96 'tls-database' : {'extra_sources' : ['gtesttlsbackend.c']},
97 'tls-bindings' : {'extra_sources' : ['gtesttlsbackend.c']},
98 'gdbus-address-get-session' : {},
102 test_extra_programs = {
103 'gdbus-connection-flush-helper' : {},
104 'gdbus-testserver' : {},
105 'gsubprocess-testprog' : {},
112 test_env = environment()
113 test_env.set('G_TEST_SRCDIR', meson.current_source_dir())
114 test_env.set('G_TEST_BUILDDIR', meson.current_build_dir())
115 test_env.set('GIO_MODULE_DIR', '')
117 # Check for libdbus1 - Optional - is only used in the GDBus test cases
118 # 1.2.14 required for dbus_message_set_serial
119 dbus1_dep = dependency('dbus-1', required : false, version : '>= 1.2.14')
120 if not dbus1_dep.found()
121 if cc.get_id() == 'msvc' or cc.get_id() == 'clang-cl'
122 # MSVC: Search for the DBus library by the configuration, which corresponds
123 # to the output of CMake builds of DBus. Note that debugoptimized
124 # is really a Release build with .PDB files.
126 dbus1_dep = cc.find_library('dbus-1d', required : false)
128 dbus1_dep = cc.find_library('dbus-1', required : false)
133 glib_conf.set('HAVE_DBUS1', 1)
136 'gdbus-serialization' : {
137 'extra_sources' : ['gdbus-tests.c'],
138 'dependencies' : [dbus1_dep],
140 'gdbus-server-auth' : {
141 'dependencies' : [dbus1_dep],
145 # We can build a cut-down version of this test without libdbus
147 'gdbus-server-auth' : {},
151 # Test programs buildable on UNIX only
152 if host_machine.system() != 'windows'
156 'dependencies' : [libgdbus_example_objectmanager_dep],
157 'install_rpath' : installed_tests_execdir
159 'gdbus-peer-object-manager' : {},
161 'socket-address' : {},
162 'stream-rw_all' : {},
166 'g-file-info-filesystem-readonly' : {},
167 'gschema-compile' : {'install' : false},
171 # LD_PRELOAD modules don't work so well with AddressSanitizer
172 if have_rtld_next and get_option('b_sanitize') == 'none'
174 'gsocketclient-slow' : {
176 shared_library('slow-connect-preload',
177 'slow-connect-preload.c',
179 dependencies: libdl_dep,
180 install_dir : installed_tests_execdir,
181 install: installed_tests_enabled,
185 'LD_PRELOAD': '@0@/slow-connect-preload.so'.format(meson.current_build_dir())
187 'installed_tests_env' : {
188 'LD_PRELOAD': '@0@/slow-connect-preload.so'.format(installed_tests_execdir),
194 # Uninstalled because of the check-for-executable logic in DesktopAppInfo
195 # unable to find the installed executable
196 if not glib_have_cocoa
201 'desktop-app-info' : {
207 test_extra_programs += {
208 'basic-application' : {},
213 if not glib_have_cocoa
214 test_extra_programs += {
222 # Test programs that need to bring up a session bus (requires dbus-daemon)
223 have_dbus_daemon = find_program('dbus-daemon', required : false).found()
226 '--annotate', 'org.project.Bar', 'Key1', 'Value1',
227 '--annotate', 'org.project.Bar', 'org.gtk.GDBus.Internal', 'Value2',
228 '--annotate', 'org.project.Bar.HelloWorld()', 'Key3', 'Value3',
229 '--annotate', 'org.project.Bar::TestSignal', 'Key4', 'Value4',
230 '--annotate', 'org.project.Bar:ay', 'Key5', 'Value5',
231 '--annotate', 'org.project.Bar.TestPrimitiveTypes()[val_int32]', 'Key6', 'Value6',
232 '--annotate', 'org.project.Bar.TestPrimitiveTypes()[ret_uint32]', 'Key7', 'Value7',
233 '--annotate', 'org.project.Bar::TestSignal[array_of_strings]', 'Key8', 'Value8',
235 # Generate gdbus-test-codegen-generated.{c,h}
236 gdbus_test_codegen_generated = custom_target('gdbus-test-codegen-generated',
237 input : ['test-codegen.xml'],
238 output : ['gdbus-test-codegen-generated.h',
239 'gdbus-test-codegen-generated.c'],
240 depend_files : gdbus_codegen_built_files,
241 command : [python, gdbus_codegen,
242 '--interface-prefix', 'org.project.',
243 '--output-directory', '@OUTDIR@',
244 '--generate-c-code', 'gdbus-test-codegen-generated',
245 '--c-generate-object-manager',
246 '--c-generate-autocleanup', 'all',
247 '--c-namespace', 'Foo_iGen',
248 '--generate-docbook', 'gdbus-test-codegen-generated-doc',
251 # Generate gdbus-test-codegen-generated-min-required-2-64.{c,h}
252 gdbus_test_codegen_generated_min_required_2_64 = custom_target('gdbus-test-codegen-generated-min-required-2-64',
253 input : ['test-codegen.xml'],
254 output : ['gdbus-test-codegen-generated-min-required-2-64.h',
255 'gdbus-test-codegen-generated-min-required-2-64.c'],
256 depend_files : gdbus_codegen_built_files,
257 command : [python, gdbus_codegen,
258 '--glib-min-required', '2.64',
259 '--interface-prefix', 'org.project.',
260 '--output-directory', '@OUTDIR@',
261 '--generate-c-code', 'gdbus-test-codegen-generated-min-required-2-64',
262 '--c-generate-object-manager',
263 '--c-generate-autocleanup', 'all',
264 '--c-namespace', 'Foo_iGen',
265 '--generate-docbook', 'gdbus-test-codegen-generated-doc',
268 gdbus_test_codegen_generated_interface_info = [
269 custom_target('gdbus-test-codegen-generated-interface-info-h',
270 input : ['test-codegen.xml'],
271 output : ['gdbus-test-codegen-generated-interface-info.h'],
272 depend_files : gdbus_codegen_built_files,
273 command : [python, gdbus_codegen,
274 '--interface-info-header',
276 '--output', '@OUTPUT@',
278 custom_target('gdbus-test-codegen-generated-interface-info-c',
279 input : ['test-codegen.xml'],
280 output : ['gdbus-test-codegen-generated-interface-info.c'],
281 depend_files : gdbus_codegen_built_files,
282 command : [python, gdbus_codegen,
283 '--interface-info-body',
285 '--output', '@OUTPUT@',
289 extra_sources = ['gdbus-sessionbus.c', 'gdbus-tests.c']
293 'extra_sources' : extra_sources,
296 'gdbus-auth' : {'extra_sources' : extra_sources},
297 'gdbus-bz627724' : {'extra_sources' : extra_sources},
298 'gdbus-close-pending' : {'extra_sources' : extra_sources},
299 'gdbus-connection' : {'extra_sources' : extra_sources},
300 'gdbus-connection-loss' : {'extra_sources' : extra_sources},
301 'gdbus-connection-slow' : {'extra_sources' : extra_sources},
302 'gdbus-error' : {'extra_sources' : extra_sources},
303 'gdbus-exit-on-close' : {'extra_sources' : extra_sources},
305 'extra_sources' : extra_sources,
308 'gdbus-introspection' : {'extra_sources' : extra_sources},
309 'gdbus-names' : {'extra_sources' : extra_sources},
310 'gdbus-proxy' : {'extra_sources' : extra_sources},
311 'gdbus-proxy-threads' : {
312 'extra_sources' : extra_sources,
313 'dependencies' : [dbus1_dep],
315 'gdbus-proxy-unique-name' : {'extra_sources' : extra_sources},
316 'gdbus-proxy-well-known-name' : {'extra_sources' : extra_sources},
317 'gdbus-test-codegen' : {
318 'extra_sources' : [extra_sources, gdbus_test_codegen_generated, gdbus_test_codegen_generated_interface_info],
319 'c_args' : ['-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_32'],
321 'gdbus-threading' : {
322 'extra_sources' : extra_sources,
326 'extra_sources' : extra_sources,
330 'extra_sources' : [extra_sources, 'gnotification-server.c'],
332 'gdbus-test-codegen-old' : {
333 'source' : 'gdbus-test-codegen.c',
334 'extra_sources' : [extra_sources, gdbus_test_codegen_generated, gdbus_test_codegen_generated_interface_info],
335 'c_args' : ['-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_36',
336 '-DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_2_36'],
338 'gdbus-test-codegen-min-required-2-64' : {
339 'source' : 'gdbus-test-codegen.c',
340 'extra_sources' : [extra_sources, gdbus_test_codegen_generated_min_required_2_64, gdbus_test_codegen_generated_interface_info],
341 'c_args' : ['-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_2_64'],
343 'gapplication' : {'extra_sources' : extra_sources},
346 if not glib_have_cocoa
349 'extra_sources' : extra_sources,
354 fake_document_portal_generated = custom_target('fake-document-portal-generated',
355 input : ['../org.freedesktop.portal.Documents.xml'],
356 output : ['fake-document-portal-generated.h',
357 'fake-document-portal-generated.c'],
358 depend_files : gdbus_codegen_built_files,
359 command : [python, gdbus_codegen,
360 '--interface-prefix', 'org.freedesktop.portal.',
361 '--output-directory', '@OUTDIR@',
362 '--generate-c-code', 'fake-document-portal-generated',
363 '--c-namespace', 'Fake',
366 test_extra_programs += {
367 'fake-document-portal' : {
368 'extra_sources': fake_document_portal_generated,
370 'fake-service-name' : {}
372 endif # have_dbus_daemon
374 # This test is currently unreliable
375 executable('gdbus-overflow', 'gdbus-overflow.c',
376 c_args : test_c_args,
377 dependencies : common_gio_tests_deps,
378 install_dir : installed_tests_execdir,
379 install : installed_tests_enabled)
382 'gdbus-connection-flush' : {
383 'extra_sources' : ['test-io-stream.c', 'test-pipe-unix.c'],
385 'gdbus-non-socket' : {
386 'extra_sources' : ['gdbus-tests.c', 'test-io-stream.c', 'test-pipe-unix.c'],
390 # Generate test.mo from de.po using msgfmt
391 msgfmt = find_program('msgfmt', required : false)
393 subdir('de/LC_MESSAGES')
396 'extra_sources' : [test_mo],
397 'c_args' : ['-DSRCDIR="@0@"'.format(meson.current_source_dir()),
398 '-DTEST_LOCALE_PATH="@0@"'.format(test_mo_dir)],
405 # Test programs buildable on Windows only
406 if host_machine.system() == 'windows'
407 gio_tests += {'win32-streams' : {}}
410 if cc.get_id() != 'msvc'
413 'source' : 'autoptr.c',
418 test_extra_programs += {
419 'gio-du' : {'install' : false},
420 'echo-server' : {'install' : false},
421 'filter-cat' : {'install' : false},
422 'gapplication-example-actions' : {'install' : false},
423 'gapplication-example-cmdline' : {'install' : false},
424 'gapplication-example-cmdline2' : {'install' : false},
425 'gapplication-example-cmdline3' : {'install' : false},
426 'gapplication-example-cmdline4' : {'install' : false},
427 'gapplication-example-dbushooks' : {'install' : false},
428 'gapplication-example-open' : {'install' : false},
430 'extra_sources' : gdbus_daemon_sources,
433 'gdbus-example-export' : {'install' : false},
434 'gdbus-example-own-name' : {'install' : false},
435 'gdbus-example-peer' : {'install' : false},
436 'gdbus-example-proxy-subclass' : {'install' : false},
437 'gdbus-example-server' : {'install' : false},
438 'gdbus-example-subtree' : {'install' : false},
439 'gdbus-example-watch-name' : {'install' : false},
440 'gdbus-example-watch-proxy' : {'install' : false},
441 'httpd' : {'install' : false},
442 'proxy' : {'install' : false},
443 'resolver' : {'install' : false},
444 'send-data' : {'install' : false},
445 'socket-server' : {'install' : false},
447 'extra_sources' : ['gtlsconsoleinteraction.c'],
452 gdbus_example_objectmanager_sources = files(
453 'gdbus-example-objectmanager-client.c',
454 'gdbus-example-objectmanager-server.c',
457 if cc.get_id() != 'msvc' and cc.get_id() != 'clang-cl'
458 test_extra_programs += {
459 # These three are manual-run tests because they need a session bus but don't bring one up themselves
460 # FIXME: these build but don't seem to work!
461 'gdbus-example-objectmanager-client' : {
462 'dependencies' : [libgdbus_example_objectmanager_dep],
465 'gdbus-example-objectmanager-server' : {
466 'dependencies' : [libgdbus_example_objectmanager_dep],
469 'gdbus-test-fixture' : {
470 'dependencies' : [libgdbus_example_objectmanager_dep],
476 if host_machine.system() != 'windows'
477 test_extra_programs += {
478 'gdbus-example-unix-fd-client' : {
484 appinfo_test_desktop_files = [
485 'appinfo-test-gnome.desktop',
486 'appinfo-test-notgnome.desktop',
487 'appinfo-test.desktop',
488 'appinfo-test2.desktop',
491 cdata = configuration_data()
492 if installed_tests_enabled
493 cdata.set('installed_tests_dir', installed_tests_execdir)
495 cdata.set('installed_tests_dir', meson.current_build_dir())
498 foreach appinfo_test_desktop_file : appinfo_test_desktop_files
499 if installed_tests_enabled
501 input: appinfo_test_desktop_file + '.in',
502 output: appinfo_test_desktop_file,
503 install_dir: installed_tests_execdir,
504 configuration: cdata,
508 input: appinfo_test_desktop_file + '.in',
509 output: appinfo_test_desktop_file,
510 configuration: cdata,
515 if installed_tests_enabled
519 'appinfo-test-actions.desktop',
520 'appinfo-test-static.desktop',
522 'org.gtk.test.dbusappinfo.desktop',
523 'org.gtk.test.dbusappinfo.flatpak.desktop',
525 install_dir : installed_tests_execdir,
527 install_subdir('x-content', install_dir : installed_tests_execdir)
528 install_subdir('desktop-files', install_dir : installed_tests_execdir)
529 install_subdir('thumbnails', install_dir : installed_tests_execdir)
530 install_subdir('cert-tests', install_dir : installed_tests_execdir)
532 cdata = configuration_data()
533 cdata.set('installed_tests_dir', installed_tests_execdir)
534 cdata.set('program', 'static-link.py ' + glib_pkgconfigreldir)
536 input: installed_tests_template,
537 output: 'static-link.test',
538 install_dir: installed_tests_metadir,
541 install_subdir('static-link', install_dir : installed_tests_execdir)
542 install_data('static-link.py', install_dir : installed_tests_execdir)
544 memory_monitor_tests = [
545 'memory-monitor-dbus',
546 'memory-monitor-portal',
549 foreach memory_monitor_test : memory_monitor_tests
550 cdata = configuration_data()
551 cdata.set('installed_tests_dir', installed_tests_execdir)
552 cdata.set('program', memory_monitor_test + '.py')
555 input: installed_tests_template_tap,
556 output: memory_monitor_test + '.test',
557 install_dir: installed_tests_metadir,
560 cdata = configuration_data()
561 cdata.set('libexecdir', join_paths(glib_prefix, get_option('libexecdir')))
563 input: memory_monitor_test + '.py.in',
564 output: memory_monitor_test + '.py',
565 install_dir : installed_tests_execdir,
566 configuration: cdata,
571 if not meson.is_cross_build() or meson.has_exe_wrapper()
573 plugin_resources_c = custom_target('plugin-resources.c',
574 input : 'test4.gresource.xml',
575 output : 'plugin-resources.c',
576 command : [glib_compile_resources,
578 '--sourcedir=' + meson.current_source_dir(),
580 '--c-name', '_g_plugin',
583 shared_module('resourceplugin', 'resourceplugin.c', plugin_resources_c,
584 link_args : export_dynamic_ldflags,
585 dependencies : common_gio_tests_deps,
586 install_dir : installed_tests_execdir,
587 install : installed_tests_enabled
590 # referenced by test2.gresource.xml
591 big_test_resource = custom_target(
592 'gresource-big-test.txt',
593 input : ['gen-big-test-resource.py'],
594 output : ['gresource-big-test.txt'],
595 command : [python, '@INPUT0@', '@OUTPUT@'])
597 test_gresource = custom_target('test.gresource',
598 input : 'test.gresource.xml',
599 output : 'test.gresource',
600 command : [glib_compile_resources,
602 '--sourcedir=' + meson.current_source_dir(),
603 '--sourcedir=' + meson.current_build_dir(),
605 install_dir : installed_tests_execdir,
606 install : installed_tests_enabled)
608 test_resources2_c = custom_target('test_resources2.c',
609 input : 'test3.gresource.xml',
610 output : 'test_resources2.c',
611 command : [glib_compile_resources,
613 '--sourcedir=' + meson.current_source_dir(),
615 '--c-name', '_g_test2',
619 test_resources2_h = custom_target('test_resources2.h',
620 input : 'test3.gresource.xml',
621 output : 'test_resources2.h',
622 command : [glib_compile_resources,
624 '--sourcedir=' + meson.current_source_dir(),
626 '--c-name', '_g_test2',
630 test_resources_c = custom_target('test_resources.c',
631 input : 'test2.gresource.xml',
632 depends : big_test_resource,
633 output : 'test_resources.c',
634 command : [glib_compile_resources,
636 '--sourcedir=' + meson.current_source_dir(),
637 '--sourcedir=' + meson.current_build_dir(),
639 '--c-name', '_g_test1',
642 digit_test_resources_c = custom_target('digit_test_resources.c',
643 input : '111_digit_test.gresource.xml',
644 output : 'digit_test_resources.c',
645 command : [glib_compile_resources,
647 '--sourcedir=' + meson.current_source_dir(),
648 '--sourcedir=' + meson.current_build_dir(),
653 digit_test_resources_h = custom_target('digit_test_resources.h',
654 input : '111_digit_test.gresource.xml',
655 output : 'digit_test_resources.h',
656 command : [glib_compile_resources,
658 '--sourcedir=' + meson.current_source_dir(),
663 # referenced by test.gresource.xml
664 test_generated_txt = configure_file(input : 'test1.txt',
665 output : 'test-generated.txt',
669 resources_extra_sources = [
674 digit_test_resources_c,
675 digit_test_resources_h,
678 # Create object file containing resource data for testing the --external-data
679 # option. Currently only GNU ld and objcopy, or (as of 2019) LLVM ld and
680 # objcopy, support the right options.
681 objcopy_supports_add_symbol = false
682 objcopy = find_program('objcopy', required : false)
684 objcopy_supports_add_symbol = run_command(objcopy, '--help').stdout().contains('--add-symbol')
687 ld = find_program('ld', required : false)
689 if build_machine.system() == 'linux' and objcopy.found() and objcopy_supports_add_symbol and ld.found()
690 test_gresource_binary = custom_target('test5.gresource',
691 input : 'test5.gresource.xml',
692 output : 'test5.gresource',
693 command : [glib_compile_resources,
695 '--sourcedir=' + meson.current_source_dir(),
696 '--sourcedir=' + meson.current_build_dir(),
698 install_dir : installed_tests_execdir,
699 install : installed_tests_enabled)
701 # Create resource data file
702 test_resources_binary_c = custom_target('test_resources_binary.c',
703 input : 'test5.gresource.xml',
704 output : 'test_resources_binary.c',
705 command : [glib_compile_resources,
707 '--sourcedir=' + meson.current_source_dir(),
708 '--sourcedir=' + meson.current_build_dir(),
711 '--c-name', '_g_binary_test1',
714 # Create object file containing resource data
715 test_resources_binary = custom_target('test_resources.o',
716 input : test_gresource_binary,
717 output : 'test_resources.o',
724 # Rename symbol to match the one in the C file
725 test_resources_binary2 = custom_target('test_resources2.o',
726 input : test_resources_binary,
727 output : 'test_resources2.o',
729 '--add-symbol','_g_binary_test1_resource_data=.data:0',
733 resources_extra_sources += [
734 test_resources_binary_c,
735 test_resources_binary2,
741 'extra_sources' : resources_extra_sources,
746 foreach test_name, extra_args : gio_tests
747 source = extra_args.get('source', test_name + '.c')
748 extra_sources = extra_args.get('extra_sources', [])
749 install = installed_tests_enabled and extra_args.get('install', true)
750 installed_tests_env = extra_args.get('installed_tests_env', {})
753 test_conf = configuration_data()
754 test_conf.set('installed_tests_dir', installed_tests_execdir)
755 test_conf.set('program', test_name)
756 test_env_override = ''
757 if installed_tests_env != {}
759 foreach var, value : installed_tests_env
760 envs += '@0@=@1@'.format(var, value)
762 test_env_override = '@0@ @1@ '.format(env_program.path(), ' '.join(envs))
764 test_conf.set('env', test_env_override)
766 input: installed_tests_template_tap,
767 output: test_name + '.test',
768 install_dir: installed_tests_metadir,
769 configuration: test_conf
773 exe = executable(test_name, [source, extra_sources],
774 c_args : test_c_args + extra_args.get('c_args', []),
775 dependencies : common_gio_tests_deps + extra_args.get('dependencies', []),
776 install_rpath : extra_args.get('install_rpath', ''),
777 install_dir: installed_tests_execdir,
781 suite = ['gio'] + extra_args.get('suite', [])
782 timeout = suite.contains('slow') ? test_timeout_slow : test_timeout
783 local_test_env = test_env
785 foreach var, value : extra_args.get('env', {})
786 local_test_env.append(var, value)
790 env : local_test_env,
793 is_parallel : extra_args.get('is_parallel', true),
794 depends : extra_args.get('depends', []),
798 foreach program_name, extra_args : test_extra_programs
799 source = extra_args.get('source', program_name + '.c')
800 extra_sources = extra_args.get('extra_sources', [])
801 install = installed_tests_enabled and extra_args.get('install', true)
802 executable(program_name, [source, extra_sources],
803 c_args : test_c_args,
804 dependencies : common_gio_tests_deps + extra_args.get('dependencies', []),
805 install_dir : installed_tests_execdir,
810 foreach test_name : python_tests
814 args: ['-B', files(test_name)],
816 suite: ['gio', 'no-valgrind'],
819 if installed_tests_enabled
822 install_dir: installed_tests_execdir,
823 install_mode: 'rwxr-xr-x',
826 test_conf = configuration_data()
827 test_conf.set('installed_tests_dir', installed_tests_execdir)
828 test_conf.set('program', test_name)
829 test_conf.set('env', '')
831 input: installed_tests_template_tap,
832 output: test_name + '.test',
833 install_dir: installed_tests_metadir,
834 configuration: test_conf,
839 # TAP test runner for Python tests
840 if installed_tests_enabled
842 files('taptestrunner.py'),
843 install_dir: installed_tests_execdir,