projects
/
tinc
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve proxy server support
[tinc]
/
test
/
unit
/
meson.build
diff --git
a/test/unit/meson.build
b/test/unit/meson.build
index
0240dc9
..
8633c18
100644
(file)
--- a/
test/unit/meson.build
+++ b/
test/unit/meson.build
@@
-17,9
+17,23
@@
link_tincd = { 'lib': lib_tincd, 'dep': deps_tincd }
# 'code': 'test1.c', // or ['test1.c', 'test1_util.c']
# 'mock': ['foo', 'bar'], // list of functions to mock (default: empty)
# 'link': link_tinc, // which binary to link with (default: tincd)
# 'code': 'test1.c', // or ['test1.c', 'test1_util.c']
# 'mock': ['foo', 'bar'], // list of functions to mock (default: empty)
# 'link': link_tinc, // which binary to link with (default: tincd)
+# 'fail': true, // whether the test should fail (default: false)
# }
tests = {
# }
tests = {
+ 'dropin': {
+ 'code': 'test_dropin.c',
+ },
+ 'random': {
+ 'code': 'test_random.c',
+ },
+ 'random_noinit': {
+ 'code': 'test_random_noinit.c',
+ 'fail': true,
+ },
+ 'netutl': {
+ 'code': 'test_netutl.c',
+ },
'net': {
'code': 'test_net.c',
'mock': ['execute_script', 'environment_init', 'environment_exit'],
'net': {
'code': 'test_net.c',
'mock': ['execute_script', 'environment_init', 'environment_exit'],
@@
-30,6
+44,19
@@
tests = {
'protocol': {
'code': 'test_protocol.c',
},
'protocol': {
'code': 'test_protocol.c',
},
+ 'proxy': {
+ 'code': 'test_proxy.c',
+ },
+ 'utils': {
+ 'code': 'test_utils.c',
+ },
+ 'xalloc': {
+ 'code': 'test_xalloc.c',
+ },
+ 'memzero_null': {
+ 'code': 'test_memzero_null.c',
+ 'fail': true,
+ },
'splay_tree': {
'code': 'test_splay_tree.c',
'link': link_tinc,
'splay_tree': {
'code': 'test_splay_tree.c',
'link': link_tinc,
@@
-59,11
+86,14
@@
foreach test, data : tests
include_directories: inc_conf,
build_by_default: false)
include_directories: inc_conf,
build_by_default: false)
+ must_fail = data.get('fail', false)
+
test(test,
exe,
suite: 'unit',
timeout: 60,
test(test,
exe,
suite: 'unit',
timeout: 60,
- protocol: 'tap',
- env: env)
+ protocol: must_fail ? 'exitcode' : 'tap',
+ env: env,
+ should_fail: must_fail)
endforeach
endforeach