OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "mojo/edk/system/core_test_base.h" | 5 #include "mojo/edk/system/core_test_base.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 | 201 |
202 CoreTestBase::MockHandleInfo* const info_; | 202 CoreTestBase::MockHandleInfo* const info_; |
203 | 203 |
204 MOJO_DISALLOW_COPY_AND_ASSIGN(MockDispatcher); | 204 MOJO_DISALLOW_COPY_AND_ASSIGN(MockDispatcher); |
205 }; | 205 }; |
206 | 206 |
207 } // namespace | 207 } // namespace |
208 | 208 |
209 // CoreTestBase ---------------------------------------------------------------- | 209 // CoreTestBase ---------------------------------------------------------------- |
210 | 210 |
| 211 // static |
| 212 constexpr MojoHandleRights CoreTestBase::kDefaultMockHandleRights; |
| 213 |
211 CoreTestBase::CoreTestBase() | 214 CoreTestBase::CoreTestBase() |
212 : platform_support_(embedder::CreateSimplePlatformSupport()) {} | 215 : platform_support_(embedder::CreateSimplePlatformSupport()) {} |
213 | 216 |
214 CoreTestBase::~CoreTestBase() {} | 217 CoreTestBase::~CoreTestBase() {} |
215 | 218 |
216 void CoreTestBase::SetUp() { | 219 void CoreTestBase::SetUp() { |
217 CHECK(!core_); | 220 CHECK(!core_); |
218 core_.reset(new Core(platform_support_.get())); | 221 core_.reset(new Core(platform_support_.get())); |
219 } | 222 } |
220 | 223 |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
435 } | 438 } |
436 | 439 |
437 void CoreTestBase_MockHandleInfo::AwakableWasAdded(Awakable* awakable) { | 440 void CoreTestBase_MockHandleInfo::AwakableWasAdded(Awakable* awakable) { |
438 MutexLocker locker(&mutex_); | 441 MutexLocker locker(&mutex_); |
439 added_awakables_.push_back(awakable); | 442 added_awakables_.push_back(awakable); |
440 } | 443 } |
441 | 444 |
442 } // namespace test | 445 } // namespace test |
443 } // namespace system | 446 } // namespace system |
444 } // namespace mojo | 447 } // namespace mojo |
OLD | NEW |