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

Unified Diff: chromeos/process_proxy/process_proxy_unittest.cc

Issue 856563004: Update {virtual,override,final} to follow C++11 style in chromeos. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « chromeos/process_proxy/process_output_watcher_unittest.cc ('k') | chromeos/settings/timezone_settings.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/process_proxy/process_proxy_unittest.cc
diff --git a/chromeos/process_proxy/process_proxy_unittest.cc b/chromeos/process_proxy/process_proxy_unittest.cc
index cb41359f55703970b0137bf3cd049c6b6a1675eb..e6b9c46d99c1c6d01609311b29af564792f91555 100644
--- a/chromeos/process_proxy/process_proxy_unittest.cc
+++ b/chromeos/process_proxy/process_proxy_unittest.cc
@@ -39,9 +39,9 @@ class TestRunner {
class RegistryTestRunner : public TestRunner {
public:
- virtual ~RegistryTestRunner() {}
+ ~RegistryTestRunner() override {}
- virtual void SetupExpectations(pid_t pid) override {
+ void SetupExpectations(pid_t pid) override {
pid_ = pid;
left_to_check_index_[0] = 0;
left_to_check_index_[1] = 0;
@@ -59,8 +59,9 @@ class RegistryTestRunner : public TestRunner {
// abc|abcdef|defgh|gh). To deal with that, we allow to test received text
// against two lines. The lines MUST NOT have two same characters for this
// algorithm to work.
- virtual void OnSomeRead(pid_t pid, const std::string& type,
- const std::string& output) override {
+ void OnSomeRead(pid_t pid,
+ const std::string& type,
+ const std::string& output) override {
EXPECT_EQ(type, kStdoutType);
EXPECT_EQ(pid_, pid);
@@ -79,7 +80,7 @@ class RegistryTestRunner : public TestRunner {
}
}
- virtual void StartRegistryTest(ProcessProxyRegistry* registry) override {
+ void StartRegistryTest(ProcessProxyRegistry* registry) override {
for (int i = 0; i < kTestLineNum; i++) {
EXPECT_TRUE(registry->SendInput(pid_, kTestLineToSend));
}
@@ -116,15 +117,16 @@ class RegistryTestRunner : public TestRunner {
class RegistryNotifiedOnProcessExitTestRunner : public TestRunner {
public:
- virtual ~RegistryNotifiedOnProcessExitTestRunner() {}
+ ~RegistryNotifiedOnProcessExitTestRunner() override {}
- virtual void SetupExpectations(pid_t pid) override {
+ void SetupExpectations(pid_t pid) override {
output_received_ = false;
pid_ = pid;
}
- virtual void OnSomeRead(pid_t pid, const std::string& type,
- const std::string& output) override {
+ void OnSomeRead(pid_t pid,
+ const std::string& type,
+ const std::string& output) override {
EXPECT_EQ(pid_, pid);
if (!output_received_) {
output_received_ = true;
@@ -138,7 +140,7 @@ class RegistryNotifiedOnProcessExitTestRunner : public TestRunner {
base::MessageLoop::QuitClosure());
}
- virtual void StartRegistryTest(ProcessProxyRegistry* registry) override {
+ void StartRegistryTest(ProcessProxyRegistry* registry) override {
EXPECT_TRUE(registry->SendInput(pid_, "p"));
}
@@ -148,14 +150,13 @@ class RegistryNotifiedOnProcessExitTestRunner : public TestRunner {
class SigIntTestRunner : public TestRunner {
public:
- virtual ~SigIntTestRunner() {}
+ ~SigIntTestRunner() override {}
- virtual void SetupExpectations(pid_t pid) override {
- pid_ = pid;
- }
+ void SetupExpectations(pid_t pid) override { pid_ = pid; }
- virtual void OnSomeRead(pid_t pid, const std::string& type,
- const std::string& output) override {
+ void OnSomeRead(pid_t pid,
+ const std::string& type,
+ const std::string& output) override {
EXPECT_EQ(pid_, pid);
// We may receive ^C on stdout, but we don't care about that, as long as we
// eventually received exit event.
@@ -165,7 +166,7 @@ class SigIntTestRunner : public TestRunner {
}
}
- virtual void StartRegistryTest(ProcessProxyRegistry* registry) override {
+ void StartRegistryTest(ProcessProxyRegistry* registry) override {
// Send SingInt and verify the process exited.
EXPECT_TRUE(registry->SendInput(pid_, "\003"));
}
@@ -176,7 +177,7 @@ class SigIntTestRunner : public TestRunner {
class ProcessProxyTest : public testing::Test {
public:
ProcessProxyTest() {}
- virtual ~ProcessProxyTest() {}
+ ~ProcessProxyTest() override {}
protected:
void InitRegistryTest() {
« no previous file with comments | « chromeos/process_proxy/process_output_watcher_unittest.cc ('k') | chromeos/settings/timezone_settings.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698