blob: f3996fe6a298a277173974a240a39bbdbee5a507 [file] [log] [blame]
gtest_dep = dependency('gtest', main: true, disabler: true, required: false)
gmock_dep = dependency('gmock', disabler: true, required: false)
if not gtest_dep.found() or not gmock_dep.found()
gtest_proj = import('cmake').subproject('googletest', required: false)
if gtest_proj.found()
gtest_dep = declare_dependency(
dependencies: [
dependency('threads'),
gtest_proj.dependency('gtest'),
gtest_proj.dependency('gtest_main'),
]
)
gmock_dep = gtest_proj.dependency('gmock')
else
assert(
not get_option('tests').enabled(),
'Googletest is required if tests are enabled'
)
endif
endif
test(
'test_certs_manager',
executable(
'test-certs-manager',
'certs_manager_test.cpp',
include_directories: '..',
dependencies: [
gtest_dep,
gmock_dep,
cert_manager_dep,
],
),
timeout: 360, # Takes about 1 minute to generate all the certs. Allow 3x.
)
if not get_option('ca-cert-extension').disabled()
test(
'test_ca_certs_manager',
executable(
'test-ca-certs-manager',
'ca_certs_manager_test.cpp',
include_directories: '..',
dependencies: [
gtest_dep,
gmock_dep,
bmc_vmi_ca_dep,
],
),
)
endif