diff --git a/tests/cpp/multidevice.cpp b/tests/cpp/multidevice.cpp index 4d962ffa922..e56e8a2c8c4 100644 --- a/tests/cpp/multidevice.cpp +++ b/tests/cpp/multidevice.cpp @@ -7,7 +7,6 @@ // clang-format on #include #include -#include #ifdef NVFUSER_DISTRIBUTED #include @@ -42,7 +41,6 @@ MultiDeviceTest::MultiDeviceTest() { tensor_options_ = at::TensorOptions().dtype(at::kFloat).device(communicator_->device()); debug_print = getNvFuserEnv("MULTIDEVICE_DEBUG_PRINT") != nullptr; - disable_skip = getNvFuserEnv("MULTIDEVICE_DISABLE_SKIP") != nullptr; } MultiDeviceTest::~MultiDeviceTest() { @@ -56,10 +54,9 @@ MultiDeviceTest::~MultiDeviceTest() { } void MultiDeviceTest::SetUp() { - // Set the same random seed for all processes. NVFuserTest::SetUp(); - if (!disable_skip && !communicator_->is_available()) { + if (!communicator_->is_available()) { GTEST_SKIP() << "This test needs an available communicator."; } } diff --git a/tests/cpp/multidevice.h b/tests/cpp/multidevice.h index fa043ef3f6d..6e9f292e63d 100644 --- a/tests/cpp/multidevice.h +++ b/tests/cpp/multidevice.h @@ -49,7 +49,6 @@ class MultiDeviceTest : public NVFuserTest { Communicator* communicator_; c10::TensorOptions tensor_options_; bool debug_print; - bool disable_skip; }; // This macro is supposed to be used in a test case of a MultiDeviceTest or its diff --git a/tests/cpp/test_multidevice_pipeline.cpp b/tests/cpp/test_multidevice_pipeline.cpp index 1ec47e4986d..7a4c94d7eed 100644 --- a/tests/cpp/test_multidevice_pipeline.cpp +++ b/tests/cpp/test_multidevice_pipeline.cpp @@ -289,7 +289,7 @@ TEST_P(PipelineTestTwoStages, Communication) { do_reduction, sharded_dim, use_fusion_executor_cache] = GetParam(); - if (!disable_skip && !communicator_->isBackendAvailable(backend)) { + if (!communicator_->isBackendAvailable(backend)) { GTEST_SKIP() << "Backend not available"; } communicator_->setDefaultBackend(backend); diff --git a/tests/cpp/test_multidevice_sharding.cpp b/tests/cpp/test_multidevice_sharding.cpp index ff4c98936df..a8d73a7bdd1 100644 --- a/tests/cpp/test_multidevice_sharding.cpp +++ b/tests/cpp/test_multidevice_sharding.cpp @@ -19,7 +19,6 @@ namespace nvfuser { -using testing::Contains; using testing::Each; using testing::ElementsAre; using testing::Not; @@ -1283,4 +1282,5 @@ TEST_F(MultiDeviceTest, MultipleIncompatibleReshapes) { EXPECT_FALSE(runtime->isSegmented()); } } + } // namespace nvfuser