| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/lazy_instance.h" | 6 #include "base/lazy_instance.h" |
| 7 #include "base/memory/weak_ptr.h" | 7 #include "base/memory/weak_ptr.h" |
| 8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
| 9 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
| 10 #include "mojo/common/message_pump_mojo.h" | 10 #include "mojo/common/message_pump_mojo.h" |
| 11 #include "mojo/services/network/public/interfaces/network_service.mojom.h" | 11 #include "mojo/services/network/interfaces/network_service.mojom.h" |
| 12 #include "mojo/services/network/public/interfaces/net_address.mojom.h" | 12 #include "mojo/services/network/interfaces/net_address.mojom.h" |
| 13 #include "mojo/services/network/public/interfaces/host_resolver.mojom.h" | 13 #include "mojo/services/network/interfaces/host_resolver.mojom.h" |
| 14 #include "net/base/net_errors.h" | 14 #include "net/base/net_errors.h" |
| 15 #include "testing/gtest/include/gtest/gtest.h" | 15 #include "testing/gtest/include/gtest/gtest.h" |
| 16 #include "third_party/mojo/src/mojo/public/cpp/application/application_connectio
n.h" | 16 #include "third_party/mojo/src/mojo/public/cpp/application/application_connectio
n.h" |
| 17 #include "third_party/mojo/src/mojo/public/cpp/application/application_impl.h" | 17 #include "third_party/mojo/src/mojo/public/cpp/application/application_impl.h" |
| 18 #include "third_party/mojo/src/mojo/public/cpp/application/application_test_base
.h" | 18 #include "third_party/mojo/src/mojo/public/cpp/application/application_test_base
.h" |
| 19 #include "third_party/mojo/src/mojo/public/cpp/bindings/callback.h" | 19 #include "third_party/mojo/src/mojo/public/cpp/bindings/callback.h" |
| 20 | 20 |
| 21 namespace mojo { | 21 namespace mojo { |
| 22 | 22 |
| 23 class HostResolverTestHelper { | 23 class HostResolverTestHelper { |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 | 132 |
| 133 TEST_F(HostResolverImplTest, DropOnFloor) { | 133 TEST_F(HostResolverImplTest, DropOnFloor) { |
| 134 HostResolverPtr host_resolver; | 134 HostResolverPtr host_resolver; |
| 135 network_service_->CreateHostResolver(GetProxy(&host_resolver)); | 135 network_service_->CreateHostResolver(GetProxy(&host_resolver)); |
| 136 host_resolver->GetHostAddresses("localhost", NetAddressFamily::IPV4, | 136 host_resolver->GetHostAddresses("localhost", NetAddressFamily::IPV4, |
| 137 [](NetworkErrorPtr error, Array<NetAddressPtr> addresses) { | 137 [](NetworkErrorPtr error, Array<NetAddressPtr> addresses) { |
| 138 }); | 138 }); |
| 139 } | 139 } |
| 140 | 140 |
| 141 } // namespace mojo | 141 } // namespace mojo |
| OLD | NEW |