From b68c73a1938d382d891ace12938e990a60fc2ec0 Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Fri, 9 Aug 2024 12:14:17 +0200 Subject: components: add test on dependencies Components themselves can have public dependencies; those need to be available (as compile deps) for the combined library. Verify this by extending the test such that the public dependency is actually used in the header file. While there, also increase coverage by assertions. --- tests/test_cases/deps/TARGETS | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'tests/test_cases/deps/TARGETS') diff --git a/tests/test_cases/deps/TARGETS b/tests/test_cases/deps/TARGETS index 662eea2..b9b1344 100644 --- a/tests/test_cases/deps/TARGETS +++ b/tests/test_cases/deps/TARGETS @@ -288,6 +288,8 @@ , "+combined_shared_lib" , "+main" , "+main-dynamic" + , "+installed_static" + , "+installed_shared" ] , "asserts": [ "test -f foo/foo.hpp" @@ -301,13 +303,19 @@ , "test -f combined_static_lib/bar.hpp" , "! test -f combined_static_lib/libfoo.a" , "! test -f combined_static_lib/libbar.a" + , "! test -f combined_static_lib/foodep.hpp" + , "! test -f combined_static_lib/foo.o" + , "! test -f combined_static_lib/bar.o" , "test -f combined_shared_lib/libcombshared.so" , "test -f combined_shared_lib/foo.hpp" , "test -f combined_shared_lib/bar.hpp" + , "! test -f combined_shared_lib/foodep.hpp" , "! test -f combined_shared_lib/libfoo.a" , "! test -f combined_shared_lib/libbar.a" , "! test -f combined_shared_lib/libfoo.so" , "! test -f combined_shared_lib/libbar.so" + , "! test -f combined_shared_lib/foo.o" + , "! test -f combined_shared_lib/bar.o" , "./main/main" , "./main/main | grep 'Hello-from-main'" , "./main/main | grep 'bar.3'" @@ -316,6 +324,23 @@ , "./main-dynamic/bin/main | grep 'Hello-from-main'" , "./main-dynamic/bin/main | grep 'bar.3'" , "./main-dynamic/bin/main | grep 'foo.15'" + , "test -f installed_static/include/bar.hpp" + , "test -f installed_static/include/foo.hpp" + , "test -f installed_static/include/foodep.hpp" + , "test -f installed_static/lib/libcombstatic.a" + , "test -f installed_static/lib/libfoodep.a" + , "! test -f installed_static/lib/libbar.a" + , "! test -f installed_static/lib/libfoo.a" + , "test -f installed_shared/include/bar.hpp" + , "test -f installed_shared/include/foo.hpp" + , "test -f installed_shared/include/foodep.hpp" + , "test -f installed_shared/lib/libcombshared.so" + , "! test -f installed_shared/lib/libfoodep.a" + , "! test -f installed_shared/lib/libfoodep.so" + , "! test -f installed_shared/lib/libbar.a" + , "! test -f installed_shared/lib/libbar.so" + , "! test -f installed_shared/lib/libfoo.a" + , "! test -f installed_shared/lib/libfoo.so" ] , "data": [["TREE", null, "components"]] } -- cgit v1.2.3