aboutsummaryrefslogtreecommitdiffstats
path: root/test/gtest_environment_test.cc
diff options
context:
space:
mode:
Diffstat (limited to 'test/gtest_environment_test.cc')
-rw-r--r--test/gtest_environment_test.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/gtest_environment_test.cc b/test/gtest_environment_test.cc
index c9392614..94ea318b 100644
--- a/test/gtest_environment_test.cc
+++ b/test/gtest_environment_test.cc
@@ -35,6 +35,10 @@
#include <stdio.h>
#include <gtest/gtest.h>
+#define GTEST_IMPLEMENTATION_ 1 // Required for the next #include.
+#include "src/gtest-internal-inl.h"
+#undef GTEST_IMPLEMENTATION_
+
namespace testing {
GTEST_DECLARE_string_(filter);
}
@@ -123,6 +127,7 @@ int RunAllTests(MyEnvironment* env, FailureType failure) {
env->Reset();
env->set_failure_in_set_up(failure);
test_was_run = false;
+ testing::internal::GetUnitTestImpl()->ClearAdHocTestResult();
return RUN_ALL_TESTS();
}