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 // Mock ServerConnectionManager class for use in client unit tests. | 5 // Mock ServerConnectionManager class for use in client unit tests. |
6 | 6 |
7 #ifndef SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ | 7 #ifndef SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ |
8 #define SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ | 8 #define SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ |
9 | 9 |
10 #include <bitset> | 10 #include <bitset> |
11 #include <list> | 11 #include <list> |
12 #include <string> | 12 #include <string> |
13 #include <vector> | 13 #include <vector> |
14 | 14 |
15 #include "base/callback.h" | 15 #include "base/callback.h" |
16 #include "base/compiler_specific.h" | 16 #include "base/compiler_specific.h" |
17 #include "base/memory/scoped_vector.h" | 17 #include "base/memory/scoped_vector.h" |
18 #include "sync/engine/net/server_connection_manager.h" | 18 #include "sync/engine/net/server_connection_manager.h" |
19 #include "sync/internal_api/public/base/model_type.h" | 19 #include "sync/internal_api/public/base/model_type.h" |
20 #include "sync/internal_api/public/base/model_type_invalidation_map.h" | |
21 #include "sync/internal_api/public/base/unique_position.h" | 20 #include "sync/internal_api/public/base/unique_position.h" |
22 #include "sync/protocol/sync.pb.h" | 21 #include "sync/protocol/sync.pb.h" |
23 | 22 |
24 namespace syncer { | 23 namespace syncer { |
25 | 24 |
26 class MockConnectionManager : public ServerConnectionManager { | 25 class MockConnectionManager : public ServerConnectionManager { |
27 public: | 26 public: |
28 class MidCommitObserver { | 27 class MidCommitObserver { |
29 public: | 28 public: |
30 virtual void Observe() = 0; | 29 virtual void Observe() = 0; |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
395 std::string next_token_; | 394 std::string next_token_; |
396 | 395 |
397 sync_pb::ClientToServerMessage last_request_; | 396 sync_pb::ClientToServerMessage last_request_; |
398 | 397 |
399 DISALLOW_COPY_AND_ASSIGN(MockConnectionManager); | 398 DISALLOW_COPY_AND_ASSIGN(MockConnectionManager); |
400 }; | 399 }; |
401 | 400 |
402 } // namespace syncer | 401 } // namespace syncer |
403 | 402 |
404 #endif // SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ | 403 #endif // SYNC_TEST_ENGINE_MOCK_CONNECTION_MANAGER_H_ |
OLD | NEW |