Fixes Windows CE compatibility problem (issue http://code.google.com/p/googletest/issues/detail?id=362).
This commit is contained in:
parent
03062e2337
commit
1ea6b31d5d
@ -579,7 +579,7 @@ class ParameterizedTestCaseRegistry {
|
|||||||
// and terminate the program since we cannot guaranty correct
|
// and terminate the program since we cannot guaranty correct
|
||||||
// test case setup and tear-down in this case.
|
// test case setup and tear-down in this case.
|
||||||
ReportInvalidTestCaseType(test_case_name, file, line);
|
ReportInvalidTestCaseType(test_case_name, file, line);
|
||||||
abort();
|
posix::Abort();
|
||||||
} else {
|
} else {
|
||||||
// At this point we are sure that the object we found is of the same
|
// At this point we are sure that the object we found is of the same
|
||||||
// type we are looking for, so we downcast it to that type
|
// type we are looking for, so we downcast it to that type
|
||||||
|
@ -225,7 +225,7 @@ void DeathTestAbort(const String& message) {
|
|||||||
} else {
|
} else {
|
||||||
fprintf(stderr, "%s", message.c_str());
|
fprintf(stderr, "%s", message.c_str());
|
||||||
fflush(stderr);
|
fflush(stderr);
|
||||||
abort();
|
posix::Abort();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -115,7 +115,7 @@ TEST(FooTest, Bar) {
|
|||||||
void Check(bool condition, const char* msg) {
|
void Check(bool condition, const char* msg) {
|
||||||
if (!condition) {
|
if (!condition) {
|
||||||
printf("FAILED: %s\n", msg);
|
printf("FAILED: %s\n", msg);
|
||||||
abort();
|
testing::internal::posix::Abort();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ namespace {
|
|||||||
<< " Actual: " << actual_val << "\n"\
|
<< " Actual: " << actual_val << "\n"\
|
||||||
<< "Expected: " #expected "\n"\
|
<< "Expected: " #expected "\n"\
|
||||||
<< "Which is: " << expected_val << "\n";\
|
<< "Which is: " << expected_val << "\n";\
|
||||||
abort();\
|
::testing::internal::posix::Abort();\
|
||||||
}\
|
}\
|
||||||
} while(::testing::internal::AlwaysFalse())
|
} while(::testing::internal::AlwaysFalse())
|
||||||
|
|
||||||
@ -113,10 +113,10 @@ TEST(BarDeathTest, ThreadSafeAndFast) {
|
|||||||
g_death_test_count++;
|
g_death_test_count++;
|
||||||
|
|
||||||
GTEST_FLAG(death_test_style) = "threadsafe";
|
GTEST_FLAG(death_test_style) = "threadsafe";
|
||||||
EXPECT_DEATH_IF_SUPPORTED(abort(), "");
|
EXPECT_DEATH_IF_SUPPORTED(::testing::internal::posix::Abort(), "");
|
||||||
|
|
||||||
GTEST_FLAG(death_test_style) = "fast";
|
GTEST_FLAG(death_test_style) = "fast";
|
||||||
EXPECT_DEATH_IF_SUPPORTED(abort(), "");
|
EXPECT_DEATH_IF_SUPPORTED(::testing::internal::posix::Abort(), "");
|
||||||
}
|
}
|
||||||
|
|
||||||
#if GTEST_HAS_PARAM_TEST
|
#if GTEST_HAS_PARAM_TEST
|
||||||
|
Loading…
Reference in New Issue
Block a user