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

Side by Side Diff: ipc/mojo/ipc_mojo_bootstrap_unittest.cc

Issue 645623006: Standardize usage of virtual/override/final in ipc/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ipc/mojo/ipc_mojo_bootstrap.h" 5 #include "ipc/mojo/ipc_mojo_bootstrap.h"
6 6
7 #include "base/base_paths.h" 7 #include "base/base_paths.h"
8 #include "base/files/file.h" 8 #include "base/files/file.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "ipc/ipc_test_base.h" 10 #include "ipc/ipc_test_base.h"
11 11
12 #if defined(OS_POSIX) 12 #if defined(OS_POSIX)
13 #include "base/file_descriptor_posix.h" 13 #include "base/file_descriptor_posix.h"
14 #endif 14 #endif
15 15
16 namespace { 16 namespace {
17 17
18 class IPCMojoBootstrapTest : public IPCTestBase { 18 class IPCMojoBootstrapTest : public IPCTestBase {
19 protected: 19 protected:
20 }; 20 };
21 21
22 class TestingDelegate : public IPC::MojoBootstrap::Delegate { 22 class TestingDelegate : public IPC::MojoBootstrap::Delegate {
23 public: 23 public:
24 TestingDelegate() : passed_(false) {} 24 TestingDelegate() : passed_(false) {}
25 25
26 virtual void OnPipeAvailable( 26 void OnPipeAvailable(mojo::embedder::ScopedPlatformHandle handle) override;
27 mojo::embedder::ScopedPlatformHandle handle) override; 27 void OnBootstrapError() override;
28 virtual void OnBootstrapError() override;
29 28
30 bool passed() const { return passed_; } 29 bool passed() const { return passed_; }
31 30
32 private: 31 private:
33 bool passed_; 32 bool passed_;
34 }; 33 };
35 34
36 void TestingDelegate::OnPipeAvailable( 35 void TestingDelegate::OnPipeAvailable(
37 mojo::embedder::ScopedPlatformHandle handle) { 36 mojo::embedder::ScopedPlatformHandle handle) {
38 passed_ = true; 37 passed_ = true;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 bootstrap->Connect(); 76 bootstrap->Connect();
78 77
79 base::MessageLoop::current()->Run(); 78 base::MessageLoop::current()->Run();
80 79
81 EXPECT_TRUE(delegate.passed()); 80 EXPECT_TRUE(delegate.passed());
82 81
83 return 0; 82 return 0;
84 } 83 }
85 84
86 } // namespace 85 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698