Improves thread-safe death tests by changing to the original working directory before they are executed; also fixes out-dated comments about death tests.
This commit is contained in:
@@ -1142,7 +1142,8 @@ TEST(ParseInt32FlagTest, ParsesAndReturnsValidValue) {
|
||||
}
|
||||
|
||||
// For the same reason we are not explicitly testing everything in the
|
||||
// Test class, there are no separate tests for the following classes:
|
||||
// Test class, there are no separate tests for the following classes
|
||||
// (except for some trivial cases):
|
||||
//
|
||||
// TestCase, UnitTest, UnitTestResultPrinter.
|
||||
//
|
||||
@@ -1150,6 +1151,11 @@ TEST(ParseInt32FlagTest, ParsesAndReturnsValidValue) {
|
||||
//
|
||||
// TEST, TEST_F, RUN_ALL_TESTS
|
||||
|
||||
TEST(UnitTestTest, CanGetOriginalWorkingDir) {
|
||||
ASSERT_TRUE(UnitTest::GetInstance()->original_working_dir() != NULL);
|
||||
EXPECT_STRNE(UnitTest::GetInstance()->original_working_dir(), "");
|
||||
}
|
||||
|
||||
// This group of tests is for predicate assertions (ASSERT_PRED*, etc)
|
||||
// of various arities. They do not attempt to be exhaustive. Rather,
|
||||
// view them as smoke tests that can be easily reviewed and verified.
|
||||
|
||||
Reference in New Issue
Block a user