Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Remove problematic discovery test #336

Merged
merged 2 commits into from
Jul 26, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion src/Discovery_TEST.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,19 @@
#include "gz/transport/Uuid.hh"
#include "test_config.hh"

// Temporarily introduce a "DISABLED_ON_LINUX" macro.
// It currently does not exist upstream.
// This can be removed when it is in upstream gz-utils
// or the discovery WrongGzIp test passes on linux
#include <gz/utils/detail/ExtraTestMacros.hh>
#if defined __linux__
#define GZ_UTILS_TEST_DISABLED_ON_LINUX(TestName) \
DETAIL_GZ_UTILS_ADD_DISABLED_PREFIX(TestName)
#else
#define GZ_UTILS_TEST_DISABLED_ON_LINUX(TestName) \
TestName
#endif // defined __linux__

using namespace gz;
using namespace transport;

Expand Down Expand Up @@ -529,7 +542,7 @@ TEST(DiscoveryTest, TestActivity)

//////////////////////////////////////////////////
/// \brief Check that a wrong GZ_IP value makes HostAddr() to return 127.0.0.1
TEST(DiscoveryTest, WrongGzIp)
TEST(DiscoveryTest, GZ_UTILS_TEST_DISABLED_ON_LINUX(WrongGzIp))
{
// Save the current value of GZ_IP environment variable.
std::string gzIp;
Expand Down