Skip to content

Commit

Permalink
iox-#590 Try to fix include error on CI
Browse files Browse the repository at this point in the history
Signed-off-by: Simon Hoinkis <[email protected]>
  • Loading branch information
mossmaurice committed Feb 8, 2022
1 parent 91454e4 commit 897edd3
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 8 deletions.
14 changes: 8 additions & 6 deletions iceoryx_hoofs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -99,12 +99,14 @@ if(GTest_FOUND) # only GTest_FOUND, just in case someone want's to use iceoryx_h
$<INSTALL_INTERFACE:include/${PREFIX}>
)

target_link_libraries(iceoryx_hoofs_testing PRIVATE
${CODE_COVERAGE_LIBS}
iceoryx_hoofs
GTest::gtest
GTest::gmock
${CMAKE_DL_LIBS}
target_link_libraries(iceoryx_hoofs_testing
PUBLIC
GTest::gtest
GTest::gmock
PRIVATE
${CODE_COVERAGE_LIBS}
iceoryx_hoofs
${CMAKE_DL_LIBS}
)

if(LINUX)
Expand Down
2 changes: 1 addition & 1 deletion iceoryx_hoofs/testing/error_handler_mock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@
namespace iox
{
std::mutex ErrorHandlerMock::handler_mutex;
} // namespace iox
} // namespace iox
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

#include "iceoryx_hoofs/error_handling/error_handling.hpp"

#include <gtest/gtest.h>
#include "iceoryx_hoofs/testing/test.hpp"

namespace iox
{
Expand All @@ -31,6 +31,7 @@ class ErrorHandlerMock : protected ErrorHandler
template <typename Error>
static cxx::GenericRAII setTemporaryErrorHandler(const TypedHandlerFunction<Error>& newHandler) noexcept;

protected:
/// Needed, if you want to exchange the handler. Remember the old one and call it if it is not your error. The error
/// mock needs to be the last one exchanging the handler in tests.
static std::mutex handler_mutex;
Expand Down

0 comments on commit 897edd3

Please sign in to comment.