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

Side by Side Diff: sync/test/local_sync_test_server.cc

Issue 1545553003: Switch to standard integer types in sync/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « sync/test/local_sync_test_server.h ('k') | sync/test/mock_invalidation.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "sync/test/local_sync_test_server.h" 5 #include "sync/test/local_sync_test_server.h"
6 6
7 #include <stdint.h>
8
7 #include <string> 9 #include <string>
8 10
9 #include "base/command_line.h" 11 #include "base/command_line.h"
10 #include "base/path_service.h" 12 #include "base/path_service.h"
11 #include "base/strings/string_number_conversions.h" 13 #include "base/strings/string_number_conversions.h"
12 #include "base/values.h" 14 #include "base/values.h"
13 #include "net/test/python_utils.h" 15 #include "net/test/python_utils.h"
14 #include "net/test/spawned_test_server/spawned_test_server.h" 16 #include "net/test/spawned_test_server/spawned_test_server.h"
15 17
16 namespace syncer { 18 namespace syncer {
17 19
18 LocalSyncTestServer::LocalSyncTestServer() 20 LocalSyncTestServer::LocalSyncTestServer()
19 : LocalTestServer( 21 : LocalTestServer(
20 net::SpawnedTestServer::TYPE_HTTP, // Sync uses the HTTP scheme. 22 net::SpawnedTestServer::TYPE_HTTP, // Sync uses the HTTP scheme.
21 net::SpawnedTestServer::kLocalhost, 23 net::SpawnedTestServer::kLocalhost,
22 base::FilePath()), 24 base::FilePath()),
23 xmpp_port_(0) {} 25 xmpp_port_(0) {}
24 26
25 LocalSyncTestServer::LocalSyncTestServer(uint16 port, uint16 xmpp_port) 27 LocalSyncTestServer::LocalSyncTestServer(uint16_t port, uint16_t xmpp_port)
26 : LocalTestServer( 28 : LocalTestServer(
27 net::SpawnedTestServer::TYPE_HTTP, // Sync uses the HTTP scheme. 29 net::SpawnedTestServer::TYPE_HTTP, // Sync uses the HTTP scheme.
28 net::SpawnedTestServer::kLocalhost, 30 net::SpawnedTestServer::kLocalhost,
29 base::FilePath()), 31 base::FilePath()),
30 xmpp_port_(xmpp_port) { 32 xmpp_port_(xmpp_port) {
31 SetPort(port); 33 SetPort(port);
32 } 34 }
33 35
34 LocalSyncTestServer::~LocalSyncTestServer() {} 36 LocalSyncTestServer::~LocalSyncTestServer() {}
35 37
36 bool LocalSyncTestServer::AddCommandLineArguments( 38 bool LocalSyncTestServer::AddCommandLineArguments(
37 base::CommandLine* command_line) const { 39 base::CommandLine* command_line) const {
38 if (!LocalTestServer::AddCommandLineArguments(command_line)) 40 if (!LocalTestServer::AddCommandLineArguments(command_line))
39 return false; 41 return false;
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 if (!GetPyProtoPath(&pyproto_dir)) { 90 if (!GetPyProtoPath(&pyproto_dir)) {
89 LOG(WARNING) << "Cannot find pyproto dir for generated code. " 91 LOG(WARNING) << "Cannot find pyproto dir for generated code. "
90 << "Testserver features that rely on it will not work"; 92 << "Testserver features that rely on it will not work";
91 return true; 93 return true;
92 } 94 }
93 AppendToPythonPath(pyproto_dir.AppendASCII("sync").AppendASCII("protocol")); 95 AppendToPythonPath(pyproto_dir.AppendASCII("sync").AppendASCII("protocol"));
94 return true; 96 return true;
95 } 97 }
96 98
97 } // namespace syncer 99 } // namespace syncer
OLDNEW
« no previous file with comments | « sync/test/local_sync_test_server.h ('k') | sync/test/mock_invalidation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698