| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "mojo/public/cpp/application/service_provider_impl.h" | 5 #include "mojo/public/cpp/application/service_provider_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "gtest/gtest.h" |
| 9 #include "mojo/public/cpp/application/connect.h" | 10 #include "mojo/public/cpp/application/connect.h" |
| 10 #include "mojo/public/cpp/bindings/strong_binding.h" | 11 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 11 #include "mojo/public/cpp/system/macros.h" | 12 #include "mojo/public/cpp/system/macros.h" |
| 12 #include "mojo/public/cpp/utility/run_loop.h" | 13 #include "mojo/public/cpp/utility/run_loop.h" |
| 13 #include "mojo/public/interfaces/application/service_provider.mojom.h" | 14 #include "mojo/public/interfaces/application/service_provider.mojom.h" |
| 14 #include "mojo/public/interfaces/bindings/tests/ping_service.mojom.h" | 15 #include "mojo/public/interfaces/bindings/tests/ping_service.mojom.h" |
| 15 #include "testing/gtest/include/gtest/gtest.h" | |
| 16 | 16 |
| 17 namespace mojo { | 17 namespace mojo { |
| 18 namespace { | 18 namespace { |
| 19 | 19 |
| 20 class ServiceProviderImplTest : public testing::Test { | 20 class ServiceProviderImplTest : public testing::Test { |
| 21 public: | 21 public: |
| 22 ServiceProviderImplTest() {} | 22 ServiceProviderImplTest() {} |
| 23 ~ServiceProviderImplTest() override { loop_.RunUntilIdle(); } | 23 ~ServiceProviderImplTest() override { loop_.RunUntilIdle(); } |
| 24 | 24 |
| 25 RunLoop& loop() { return loop_; } | 25 RunLoop& loop() { return loop_; } |
| (...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 343 InterfaceRequest<ServiceProvider>()); | 343 InterfaceRequest<ServiceProvider>()); |
| 344 EXPECT_EQ(ConnectionContext::Type::UNKNOWN, impl.connection_context().type); | 344 EXPECT_EQ(ConnectionContext::Type::UNKNOWN, impl.connection_context().type); |
| 345 EXPECT_EQ(std::string(), impl.connection_context().remote_url); | 345 EXPECT_EQ(std::string(), impl.connection_context().remote_url); |
| 346 EXPECT_EQ(std::string(), impl.connection_context().connection_url); | 346 EXPECT_EQ(std::string(), impl.connection_context().connection_url); |
| 347 } | 347 } |
| 348 | 348 |
| 349 // TODO(vtl): Explicitly test |AddServiceForName()|? | 349 // TODO(vtl): Explicitly test |AddServiceForName()|? |
| 350 | 350 |
| 351 } // namespace | 351 } // namespace |
| 352 } // namespace mojo | 352 } // namespace mojo |
| OLD | NEW |