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

Side by Side Diff: ppapi/tests/test_host_resolver.h

Issue 17314012: Move PPB_TCPSocket out of dev. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 months 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/tests/all_cpp_includes.h ('k') | ppapi/tests/test_host_resolver.cc » ('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 #ifndef PPAPI_TESTS_TEST_HOST_RESOLVER_H_ 5 #ifndef PPAPI_TESTS_TEST_HOST_RESOLVER_H_
6 #define PPAPI_TESTS_TEST_HOST_RESOLVER_H_ 6 #define PPAPI_TESTS_TEST_HOST_RESOLVER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "ppapi/c/dev/ppb_host_resolver_dev.h" 10 #include "ppapi/c/dev/ppb_host_resolver_dev.h"
11 #include "ppapi/tests/test_case.h" 11 #include "ppapi/tests/test_case.h"
12 12
13 namespace pp { 13 namespace pp {
14 class HostResolver_Dev; 14 class HostResolver_Dev;
15 class NetAddress; 15 class NetAddress;
16 class TCPSocket_Dev; 16 class TCPSocket;
17 } // namespace pp 17 } // namespace pp
18 18
19 class TestHostResolver : public TestCase { 19 class TestHostResolver : public TestCase {
20 public: 20 public:
21 explicit TestHostResolver(TestingInstance* instance); 21 explicit TestHostResolver(TestingInstance* instance);
22 22
23 // TestCase implementation. 23 // TestCase implementation.
24 virtual bool Init(); 24 virtual bool Init();
25 virtual void RunTests(const std::string& filter); 25 virtual void RunTests(const std::string& filter);
26 26
27 private: 27 private:
28 std::string SyncConnect(pp::TCPSocket_Dev* socket, 28 std::string SyncConnect(pp::TCPSocket* socket,
29 const pp::NetAddress& address); 29 const pp::NetAddress& address);
30 std::string SyncRead(pp::TCPSocket_Dev* socket, 30 std::string SyncRead(pp::TCPSocket* socket,
31 char* buffer, 31 char* buffer,
32 int32_t num_bytes, 32 int32_t num_bytes,
33 int32_t* bytes_read); 33 int32_t* bytes_read);
34 std::string SyncWrite(pp::TCPSocket_Dev* socket, 34 std::string SyncWrite(pp::TCPSocket* socket,
35 const char* buffer, 35 const char* buffer,
36 int32_t num_bytes, 36 int32_t num_bytes,
37 int32_t* bytes_written); 37 int32_t* bytes_written);
38 std::string CheckHTTPResponse(pp::TCPSocket_Dev* socket, 38 std::string CheckHTTPResponse(pp::TCPSocket* socket,
39 const std::string& request, 39 const std::string& request,
40 const std::string& response); 40 const std::string& response);
41 std::string SyncResolve(pp::HostResolver_Dev* host_resolver, 41 std::string SyncResolve(pp::HostResolver_Dev* host_resolver,
42 const std::string& host, 42 const std::string& host,
43 uint16_t port, 43 uint16_t port,
44 const PP_HostResolver_Hint_Dev& hint); 44 const PP_HostResolver_Hint_Dev& hint);
45 std::string ParameterizedTestResolve(const PP_HostResolver_Hint_Dev& hint); 45 std::string ParameterizedTestResolve(const PP_HostResolver_Hint_Dev& hint);
46 46
47 std::string TestEmpty(); 47 std::string TestEmpty();
48 std::string TestResolve(); 48 std::string TestResolve();
49 std::string TestResolveIPv4(); 49 std::string TestResolveIPv4();
50 50
51 std::string host_; 51 std::string host_;
52 uint16_t port_; 52 uint16_t port_;
53 }; 53 };
54 54
55 #endif // PPAPI_TESTS_TEST_HOST_RESOLVER_H_ 55 #endif // PPAPI_TESTS_TEST_HOST_RESOLVER_H_
OLDNEW
« no previous file with comments | « ppapi/tests/all_cpp_includes.h ('k') | ppapi/tests/test_host_resolver.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698