diff --git a/tests/test_cases/simulation/test_mpi_ensemble.cu b/tests/test_cases/simulation/test_mpi_ensemble.cu index 0b5463269..1d3bb1f80 100644 --- a/tests/test_cases/simulation/test_mpi_ensemble.cu +++ b/tests/test_cases/simulation/test_mpi_ensemble.cu @@ -136,8 +136,8 @@ class TestMPIEnsemble : public testing::Test { }; TEST_F(TestMPIEnsemble, success) { initEnsemble(); - const unsigned int successful_runs = ensemble->simulate(*plans); - EXPECT_EQ(successful_runs, 100u); + const unsigned int err_count = ensemble->simulate(*plans); + EXPECT_EQ(err_count, 0u); // Get stderr and stdout std::string output = testing::internal::GetCapturedStdout(); std::string errors = testing::internal::GetCapturedStderr(); @@ -158,11 +158,11 @@ TEST_F(TestMPIEnsemble, error_off) { model->newLayer().addHostFunction(throw_exception); initEnsemble(); ensemble->Config().error_level = CUDAEnsemble::EnsembleConfig::Off; - unsigned int successful_runs = 0; - EXPECT_NO_THROW(successful_runs = ensemble->simulate(*plans)); + unsigned int err_count = 0; + EXPECT_NO_THROW(err_count = ensemble->simulate(*plans)); // With error off, we would expect to see run index 12 fail // Therefore 99 returned instead of 100 - EXPECT_EQ(successful_runs, 99u); + EXPECT_EQ(err_count, 1u); // Get stderr and stdout std::string output = testing::internal::GetCapturedStdout(); std::string errors = testing::internal::GetCapturedStderr();