| 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 "base/macros.h" | 5 #include "base/macros.h" |
| 6 #include "components/resource_provider/test.mojom.h" | 6 #include "components/resource_provider/test.mojom.h" |
| 7 #include "mojo/public/cpp/bindings/string.h" | 7 #include "mojo/public/cpp/bindings/string.h" |
| 8 #include "mojo/shell/public/cpp/shell_test.h" | 8 #include "services/shell/public/cpp/shell_test.h" |
| 9 | 9 |
| 10 namespace resource_provider { | 10 namespace resource_provider { |
| 11 namespace test { | 11 namespace test { |
| 12 | 12 |
| 13 class ResourceProviderTest : public mojo::test::ShellTest { | 13 class ResourceProviderTest : public mojo::test::ShellTest { |
| 14 public: | 14 public: |
| 15 ResourceProviderTest() | 15 ResourceProviderTest() |
| 16 : mojo::test::ShellTest("exe:resource_provider_unittests") {} | 16 : mojo::test::ShellTest("exe:resource_provider_unittests") {} |
| 17 ~ResourceProviderTest() override {} | 17 ~ResourceProviderTest() override {} |
| 18 | 18 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 32 mojom::TestPtr test_app; | 32 mojom::TestPtr test_app; |
| 33 mojo::String resource1, resource2; | 33 mojo::String resource1, resource2; |
| 34 connector()->ConnectToInterface("mojo:resource_provider_test_app", &test_app); | 34 connector()->ConnectToInterface("mojo:resource_provider_test_app", &test_app); |
| 35 ASSERT_TRUE(test_app->GetBothResources(&resource1, &resource2)); | 35 ASSERT_TRUE(test_app->GetBothResources(&resource1, &resource2)); |
| 36 EXPECT_EQ("test data\n", resource1); | 36 EXPECT_EQ("test data\n", resource1); |
| 37 EXPECT_EQ("xxyy\n", resource2); | 37 EXPECT_EQ("xxyy\n", resource2); |
| 38 } | 38 } |
| 39 | 39 |
| 40 } // namespace test | 40 } // namespace test |
| 41 } // namespace resource_provider | 41 } // namespace resource_provider |
| OLD | NEW |