Add a meson option to enable googletest
This adds infrastructure to enable and support unit tests using
googletest.
Tested:
Confirmed that the option correctly enables googletest.
Signed-off-by: Jason M. Bills <jason.m.bills@linux.intel.com>
Change-Id: I8a93305391cc69b607ce5e22390f3140455e66e0
diff --git a/meson.build b/meson.build
index 8bb3675..06035ff 100644
--- a/meson.build
+++ b/meson.build
@@ -61,13 +61,19 @@
]
endif
+incs = include_directories('include')
+
executable(
'host-error-monitor',
'src/host_error_monitor.cpp',
- include_directories: include_directories('include'),
+ include_directories: incs,
dependencies: deps,
install: true,
install_dir: bindir
)
subdir('service_files')
+
+if get_option('tests').enabled()
+ subdir('tests')
+endif