Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9482)

Unified Diff: chromecast/base/process_utils_unittest.cc

Issue 1154383006: Adding crash utilities to chromecast/crash. (Closed) Base URL: https://eureka-internal.googlesource.com/chromium/src@master
Patch Set: Fix old Android build issue. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chromecast/base/process_utils_unittest.cc
diff --git a/chromecast/base/process_utils_unittest.cc b/chromecast/base/process_utils_unittest.cc
index 42e56a295ef743bdece4256277208e42e85485c4..7e31519cfc82322d510fd7a5c01be3f5a7760125 100644
--- a/chromecast/base/process_utils_unittest.cc
+++ b/chromecast/base/process_utils_unittest.cc
@@ -15,11 +15,11 @@ TEST(ProcessUtilsTest, SimpleProcess) {
args.push_back("Hello World");
// Execute the command and collect the output.
- std::string stdout;
- ASSERT_TRUE(GetAppOutput(args, &stdout));
+ std::string stdout_str;
+ ASSERT_TRUE(GetAppOutput(args, &stdout_str));
// Echo will append a newline to the stdout.
- EXPECT_EQ("Hello World\n", stdout);
+ EXPECT_EQ("Hello World\n", stdout_str);
}
// Verify that false is returned for an invalid command.
@@ -29,9 +29,9 @@ TEST(ProcessUtilsTest, InvalidCommand) {
args.push_back("invalid_command");
// The command should not run.
- std::string stdout;
- ASSERT_FALSE(GetAppOutput(args, &stdout));
- ASSERT_TRUE(stdout.empty());
+ std::string stdout_str;
+ ASSERT_FALSE(GetAppOutput(args, &stdout_str));
+ ASSERT_TRUE(stdout_str.empty());
}
// Verify that false is returned when a command an error code.
@@ -44,9 +44,9 @@ TEST(ProcessUtilsTest, ProcessReturnsError) {
// Execute the command and collect the output. Verify that the output of the
// process is collected, even when the process returns an error code.
- std::string stderr;
- ASSERT_FALSE(GetAppOutput(args, &stderr));
- ASSERT_FALSE(stderr.empty());
+ std::string stderr_str;
+ ASSERT_FALSE(GetAppOutput(args, &stderr_str));
+ ASSERT_FALSE(stderr_str.empty());
}
} // namespace chromecast

Powered by Google App Engine
This is Rietveld 408576698