Close a window for a race with the system linker
[chromium-blink-merge.git] / ppapi / tests / test_net_address_private_untrusted.h
blobf1f046278f625f92d4eef18780eb9a6d17b4839a
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
3 // found in the LICENSE file.
5 #ifndef PAPPI_TESTS_TEST_NET_ADDRESS_PRIVATE_UNTRUSTED_H_
6 #define PAPPI_TESTS_TEST_NET_ADDRESS_PRIVATE_UNTRUSTED_H_
8 #include <string>
10 #include "ppapi/cpp/private/tcp_socket_private.h"
11 #include "ppapi/tests/test_case.h"
13 // TestNetAddressPrivate doesn't compile via NaCl toolchain, because
14 // these tests depend on network API which is not available in
15 // NaCl. TestNetAddressPrivateUntrusted is written only for check that
16 // API is correctly exposed to NaCl, not for checking correctness of
17 // API --- this is a job of TestNetAddressPrivate.
18 class TestNetAddressPrivateUntrusted : public TestCase {
19 public:
20 explicit TestNetAddressPrivateUntrusted(TestingInstance* instance);
22 // TestCase implementation.
23 virtual bool Init();
24 virtual void RunTests(const std::string& filter);
26 private:
27 int32_t Connect(pp::TCPSocketPrivate* socket,
28 const std::string& host,
29 uint16_t port);
31 std::string TestAreEqual();
32 std::string TestAreHostsEqual();
33 std::string TestDescribe();
34 std::string TestReplacePort();
35 std::string TestGetAnyAddress();
36 std::string TestGetFamily();
37 std::string TestGetPort();
38 std::string TestGetAddress();
40 std::string host_;
41 uint16_t port_;
44 #endif // PAPPI_TESTS_TEST_NET_ADDRESS_PRIVATE_UNTRUSTED_H_