OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "components/sync/base/weak_handle.h" | 5 #include "components/sync/base/weak_handle.h" |
6 | 6 |
7 #include "base/bind.h" | |
8 #include "base/compiler_specific.h" | |
9 #include "base/location.h" | |
10 #include "base/memory/weak_ptr.h" | |
11 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
12 #include "base/single_thread_task_runner.h" | |
13 #include "base/threading/thread.h" | 8 #include "base/threading/thread.h" |
14 #include "testing/gmock/include/gmock/gmock.h" | 9 #include "testing/gmock/include/gmock/gmock.h" |
15 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
16 | 11 |
17 namespace syncer { | 12 namespace syncer { |
18 | 13 |
19 using ::testing::_; | 14 using ::testing::_; |
20 using ::testing::SaveArg; | 15 using ::testing::SaveArg; |
21 using ::testing::StrictMock; | 16 using ::testing::StrictMock; |
22 | 17 |
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 EXPECT_FALSE(base_weak_handle.IsInitialized()); | 307 EXPECT_FALSE(base_weak_handle.IsInitialized()); |
313 } | 308 } |
314 | 309 |
315 TEST_F(WeakHandleTest, TypeConversionConstructorUninitializedAssignment) { | 310 TEST_F(WeakHandleTest, TypeConversionConstructorUninitializedAssignment) { |
316 WeakHandle<Base> base_weak_handle; | 311 WeakHandle<Base> base_weak_handle; |
317 base_weak_handle = WeakHandle<Derived>(); | 312 base_weak_handle = WeakHandle<Derived>(); |
318 EXPECT_FALSE(base_weak_handle.IsInitialized()); | 313 EXPECT_FALSE(base_weak_handle.IsInitialized()); |
319 } | 314 } |
320 | 315 |
321 } // namespace syncer | 316 } // namespace syncer |
OLD | NEW |