Skip to content

Commit b3da340

Browse files
committed
Enable test only on Linux and disable it on Github Actions
There seems to be a race condition that causes the test to hang when CPU usage is high. This seems to be the issue on Github Actions, so, we run the Gui_clean_exit_TEST only on Jenkins. Signed-off-by: Addisu Z. Taddese <[email protected]>
1 parent 05074d7 commit b3da340

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/gui/Gui_clean_exit_TEST.cc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,14 @@ void startBoth(const std::string &_fileName)
7373
}
7474

7575
/////////////////////////////////////////////////
76-
TEST_P(GazeboDeathTest, IGN_UTILS_TEST_DISABLED_ON_MAC(CleanExit))
76+
TEST_P(GazeboDeathTest, IGN_UTILS_TEST_ENABLED_ONLY_ON_LINUX(CleanExit))
7777
{
78+
std::string githubAction;
79+
if (common::env("GITHUB_ACTION", githubAction))
80+
{
81+
GTEST_SKIP();
82+
}
83+
7884
const auto sdfFile =
7985
common::joinPaths(PROJECT_SOURCE_PATH, "test", "worlds", GetParam());
8086
ASSERT_TRUE(common::exists(sdfFile))
@@ -92,6 +98,6 @@ INSTANTIATE_TEST_SUITE_P(WorldFiles, GazeboDeathTest,
9298
int main(int _argc, char **_argv)
9399
{
94100
::testing::InitGoogleTest(&_argc, _argv);
95-
::testing::FLAGS_gtest_death_test_style = "threadsafe";
101+
::testing::FLAGS_gtest_death_test_style = "fast";
96102
return RUN_ALL_TESTS();
97103
}

0 commit comments

Comments
 (0)