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 "sync/internal_api/js_sync_manager_observer.h" | 5 #include "sync/internal_api/js_sync_manager_observer.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
11 #include "sync/internal_api/public/sessions/sync_session_snapshot.h" | 11 #include "sync/internal_api/public/sessions/sync_session_snapshot.h" |
12 #include "sync/internal_api/public/syncable/model_type.h" | 12 #include "sync/internal_api/public/syncable/model_type.h" |
| 13 #include "sync/internal_api/public/util/weak_handle.h" |
13 #include "sync/js/js_event_details.h" | 14 #include "sync/js/js_event_details.h" |
14 #include "sync/js/js_test_util.h" | 15 #include "sync/js/js_test_util.h" |
15 #include "sync/protocol/sync_protocol_error.h" | 16 #include "sync/protocol/sync_protocol_error.h" |
16 #include "sync/util/weak_handle.h" | |
17 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
18 | 18 |
19 namespace browser_sync { | 19 namespace browser_sync { |
20 namespace { | 20 namespace { |
21 | 21 |
22 using ::testing::InSequence; | 22 using ::testing::InSequence; |
23 using ::testing::StrictMock; | 23 using ::testing::StrictMock; |
24 | 24 |
25 class JsSyncManagerObserverTest : public testing::Test { | 25 class JsSyncManagerObserverTest : public testing::Test { |
26 protected: | 26 protected: |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
210 HandleJsEvent("onEncryptedTypesChanged", | 210 HandleJsEvent("onEncryptedTypesChanged", |
211 HasDetailsAsDictionary(expected_details))); | 211 HasDetailsAsDictionary(expected_details))); |
212 | 212 |
213 js_sync_manager_observer_.OnEncryptedTypesChanged( | 213 js_sync_manager_observer_.OnEncryptedTypesChanged( |
214 encrypted_types, encrypt_everything); | 214 encrypted_types, encrypt_everything); |
215 PumpLoop(); | 215 PumpLoop(); |
216 } | 216 } |
217 | 217 |
218 } // namespace | 218 } // namespace |
219 } // namespace browser_sync | 219 } // namespace browser_sync |
OLD | NEW |