[glib-networking/wip/nacho/openssl: 4/14] Add a way to skip backends for tests
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib-networking/wip/nacho/openssl: 4/14] Add a way to skip backends for tests
- Date: Wed, 19 Sep 2018 15:34:39 +0000 (UTC)
commit dd181704a7283f7c44c1ce442c4b1cd21058577d
Author: Ignacio Casal Quinteiro <qignacio amazon com>
Date: Mon Sep 10 15:34:23 2018 +0200
Add a way to skip backends for tests
tls/tests/meson.build | 74 ++++++++++++++++++++++++++-------------------------
1 file changed, 38 insertions(+), 36 deletions(-)
---
diff --git a/tls/tests/meson.build b/tls/tests/meson.build
index 3bdba0e..6198f70 100644
--- a/tls/tests/meson.build
+++ b/tls/tests/meson.build
@@ -22,10 +22,10 @@ envs = [
]
test_programs = [
- ['certificate', [], deps],
- ['file-database', [], deps],
- ['connection', ['mock-interaction.c'], deps],
- ['dtls-connection', ['mock-interaction.c'], deps],
+ ['certificate', [], deps, []],
+ ['file-database', [], deps, []],
+ ['connection', ['mock-interaction.c'], deps, []],
+ ['dtls-connection', ['mock-interaction.c'], deps, ['openssl']],
]
if pkcs11_dep.found()
@@ -44,44 +44,46 @@ endif
foreach backend: backends
foreach program: test_programs
- program_name = program[0] + '-' + backend
+ if not program[3].contains(backend)
+ program_name = program[0] + '-' + backend
- test_conf = configuration_data()
- test_conf.set('installed_tests_dir', installed_tests_execdir)
- test_conf.set('program', program_name)
+ test_conf = configuration_data()
+ test_conf.set('installed_tests_dir', installed_tests_execdir)
+ test_conf.set('program', program_name)
- if enable_installed_tests
- configure_file(
- input: test_template,
- output: program_name + '.test',
- install_dir: installed_tests_metadir,
- configuration: test_conf
- )
- endif
+ if enable_installed_tests
+ configure_file(
+ input: test_template,
+ output: program_name + '.test',
+ install_dir: installed_tests_metadir,
+ configuration: test_conf
+ )
+ endif
- test_cflags = cflags + [
- '-DBACKEND="@0@"'.format(backend),
- ]
+ test_cflags = cflags + [
+ '-DBACKEND="@0@"'.format(backend),
+ ]
- exe = executable(
- program_name,
- [program[0] + '.c'] + program[1],
- include_directories: incs,
- dependencies: program[2],
- c_args: test_cflags,
- install: enable_installed_tests,
- install_dir: installed_tests_execdir
- )
+ exe = executable(
+ program_name,
+ [program[0] + '.c'] + program[1],
+ include_directories: incs,
+ dependencies: program[2],
+ c_args: test_cflags,
+ install: enable_installed_tests,
+ install_dir: installed_tests_execdir
+ )
- test_envs = envs + [
- 'GIO_MODULE_DIR=' + join_paths(meson.build_root(), 'tls', backend)
- ]
+ test_envs = envs + [
+ 'GIO_MODULE_DIR=' + join_paths(meson.build_root(), 'tls', backend)
+ ]
- test(
- program_name,
- exe,
- env: test_envs
- )
+ test(
+ program_name,
+ exe,
+ env: test_envs
+ )
+ endif
endforeach
endforeach
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]