| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/files/scoped_temp_dir.h" | 5 #include "base/files/scoped_temp_dir.h" |
| 6 #include "mojo/runner/context.h" | 6 #include "mojo/runner/context.h" |
| 7 #include "mojo/runner/url_resolver.h" | 7 #include "mojo/runner/url_resolver.h" |
| 8 #include "mojo/shell/application_manager.h" | 8 #include "mojo/shell/application_manager.h" |
| 9 #include "mojo/util/filename_util.h" | 9 #include "mojo/util/filename_util.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 ASSERT_TRUE(temp_dir.CreateUniqueTempDir()); | 99 ASSERT_TRUE(temp_dir.CreateUniqueTempDir()); |
| 100 base::FilePath nonexistent_file(FILE_PATH_LITERAL("nonexistent.txt")); | 100 base::FilePath nonexistent_file(FILE_PATH_LITERAL("nonexistent.txt")); |
| 101 GURL url(util::FilePathToFileURL(temp_dir.path().Append(nonexistent_file))); | 101 GURL url(util::FilePathToFileURL(temp_dir.path().Append(nonexistent_file))); |
| 102 InterfaceRequest<ServiceProvider> services; | 102 InterfaceRequest<ServiceProvider> services; |
| 103 ServiceProviderPtr service_provider; | 103 ServiceProviderPtr service_provider; |
| 104 mojo::URLRequestPtr request(mojo::URLRequest::New()); | 104 mojo::URLRequestPtr request(mojo::URLRequest::New()); |
| 105 request->url = mojo::String::From(url.spec()); | 105 request->url = mojo::String::From(url.spec()); |
| 106 application_manager_.ConnectToApplication( | 106 application_manager_.ConnectToApplication( |
| 107 nullptr, request.Pass(), std::string(), GURL(), services.Pass(), | 107 nullptr, request.Pass(), std::string(), GURL(), services.Pass(), |
| 108 service_provider.Pass(), shell::GetPermissiveCapabilityFilter(), | 108 service_provider.Pass(), shell::GetPermissiveCapabilityFilter(), |
| 109 base::Closure()); | 109 base::Closure(), shell::EmptyConnectCallback()); |
| 110 EXPECT_FALSE(state_.runner_was_created); | 110 EXPECT_FALSE(state_.runner_was_created); |
| 111 EXPECT_FALSE(state_.runner_was_started); | 111 EXPECT_FALSE(state_.runner_was_started); |
| 112 EXPECT_FALSE(state_.runner_was_destroyed); | 112 EXPECT_FALSE(state_.runner_was_destroyed); |
| 113 } | 113 } |
| 114 | 114 |
| 115 } // namespace | 115 } // namespace |
| 116 } // namespace runner | 116 } // namespace runner |
| 117 } // namespace mojo | 117 } // namespace mojo |
| OLD | NEW |