diff options
author | Naoto Yamaguchi <naoto.yamaguchi@aisin.co.jp> | 2022-07-04 07:23:53 +0900 |
---|---|---|
committer | Naoto Yamaguchi <naoto.yamaguchi@aisin.co.jp> | 2022-07-30 23:42:18 +0900 |
commit | e8a05c6f1ac288a8cfa5b0837313fec8fb7aadaf (patch) | |
tree | 4f43e3521ea2384f7298a6f00406aab631f44cde /test/Makefile.am | |
parent | e5f52b7e2305019651fe4b6351d3466638af3488 (diff) |
Add test case for librefop
The librefop aim to 100% code coverage testing.
This patch add test case with mock to aim to that criteria.
Bug-AGL: SPEC-4500
Signed-off-by: Naoto Yamaguchi <naoto.yamaguchi@aisin.co.jp>
Change-Id: I4bf14d343b9fca784fb7bc3ee6d3e53691a5ea4e
Diffstat (limited to 'test/Makefile.am')
-rw-r--r-- | test/Makefile.am | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/test/Makefile.am b/test/Makefile.am new file mode 100644 index 0000000..050390e --- /dev/null +++ b/test/Makefile.am @@ -0,0 +1,60 @@ +AUTOMAKE_OPTIONS = foreign +ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS} + +bin_PROGRAMS = \ + interface_test interface_test_unit \ + fileop_test_utils \ + file_util_test + +interface_test_SOURCES = \ + interface_test.cpp \ + ../lib/static-configurator.c \ + ../lib/file-util.c \ + ../lib/fileop.c + +interface_test_unit_SOURCES = \ + interface_test_unit.cpp \ + ../lib/static-configurator.c \ + ../lib/file-util.c \ + ../lib/fileop.c + +fileop_test_utils_SOURCES = \ + fileop_test_utils.cpp \ + ../lib/static-configurator.c \ + ../lib/file-util.c + +file_util_test_SOURCES = \ + file_util_test.cpp + +# options +# Additional library +LDADD = \ + -lrt -lpthread \ + @GTEST_MAIN_LIBS@ \ + @GMOCK_MAIN_LIBS@ + +interface_test_LDADD = \ + ${LDADD} + +# C compiler options +CFLAGS = \ + -g \ + -fsanitize=address -coverage \ + -I$(top_srcdir)/lib \ + -I$(top_srcdir)/include \ + -D_GNU_SOURCE + +# C++ compiler options +CXXFLAGS = \ + -g \ + -std=c++11 -fno-exceptions \ + -fsanitize=address -coverage \ + -I$(top_srcdir)/lib \ + -I$(top_srcdir)/include \ + -D_GNU_SOURCE + +# Linker options +LDFLAGS = + + +CLEANFILES = *.gcda *.gcno |