Add tests for sign/verify commands
[tinc] / test / integration / meson.build
1 tests = [
2   'basic.py',
3   'cmd_fsck.py',
4   'cmd_sign_verify.py',
5   'commandline.py',
6   'executables.py',
7   'import_export.py',
8   'invite.py',
9   'invite_tinc_up.py',
10   'proxy.py',
11   'sandbox.py',
12   'scripts.py',
13   'security.py',
14   'splice.py',
15   'sptps_basic.py',
16   'variables.py',
17 ]
18
19 if opt_crypto != 'nolegacy'
20   tests += [
21     'algorithms.py',
22     'legacy_protocol.py',
23   ]
24 endif
25
26 if os_name == 'linux'
27   tests += [
28     'ns_ping.py',
29     'compression.py',
30   ]
31 endif
32
33 exe_splice = executable(
34   'splice',
35   sources: 'splice.c',
36   dependencies: deps_common,
37   implicit_include_directories: false,
38   include_directories: inc_conf,
39   build_by_default: false,
40 )
41
42 env_vars = {
43   'TINC_PATH': exe_tinc.full_path(),
44   'TINCD_PATH': exe_tincd.full_path(),
45   'PYTHON_PATH': python_path,
46   'SPLICE_PATH': exe_splice.full_path(),
47   'SPTPS_TEST_PATH': exe_sptps_test.full_path(),
48   'SPTPS_KEYPAIR_PATH': exe_sptps_keypair.full_path(),
49 }
50
51 deps_test = [
52   exe_tinc,
53   exe_tincd,
54   exe_splice,
55   exe_sptps_test,
56   exe_sptps_keypair,
57 ]
58
59 test_wd = meson.current_build_dir()
60 test_src = meson.current_source_dir()
61
62 foreach test_name : tests
63   if meson_version.version_compare('>=0.52')
64     env = environment(env_vars)
65   else
66     env = environment()
67     foreach k, v : env_vars
68       env.set(k, v)
69     endforeach
70   endif
71   env.set('TEST_NAME', test_name)
72
73   test(test_name,
74        python,
75        args: test_src / test_name,
76        suite: 'integration',
77        timeout: 60,
78        env: env,
79        depends: deps_test,
80        workdir: test_wd)
81 endforeach
82