Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(188)

Side by Side Diff: mojo/shell/fetcher/about_fetcher_unittest.cc

Issue 1686223002: Move InterfaceProvider into the shell::mojom namespace like the rest of the shell interfaces. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mojo/shell/connect_util.cc ('k') | mojo/shell/package_manager/content_handler_connection.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "mojo/shell/fetcher/about_fetcher.h" 5 #include "mojo/shell/fetcher/about_fetcher.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 ~AboutFetcherTest() override {} 100 ~AboutFetcherTest() override {}
101 101
102 protected: 102 protected:
103 const TestContentHandler* html_content_handler() const { 103 const TestContentHandler* html_content_handler() const {
104 return &html_content_handler_; 104 return &html_content_handler_;
105 } 105 }
106 106
107 void ConnectAndWait(const std::string& url) { 107 void ConnectAndWait(const std::string& url) {
108 base::RunLoop run_loop; 108 base::RunLoop run_loop;
109 109
110 InterfaceProviderPtr remote_interfaces; 110 shell::mojom::InterfaceProviderPtr remote_interfaces;
111 InterfaceRequest<InterfaceProvider> remote_request = 111 shell::mojom::InterfaceProviderRequest remote_request =
112 GetProxy(&remote_interfaces); 112 GetProxy(&remote_interfaces);
113 // This connection error handler will be called when: 113 // This connection error handler will be called when:
114 // - TestContentHandler::StartApplication() has been called (please see 114 // - TestContentHandler::StartApplication() has been called (please see
115 // comments in that method); or 115 // comments in that method); or
116 // - the application manager fails to fetch the requested URL. 116 // - the application manager fails to fetch the requested URL.
117 remote_interfaces.set_connection_error_handler( 117 remote_interfaces.set_connection_error_handler(
118 [&run_loop]() { run_loop.Quit(); }); 118 [&run_loop]() { run_loop.Quit(); });
119 119
120 scoped_ptr<ConnectToApplicationParams> params( 120 scoped_ptr<ConnectToApplicationParams> params(
121 new ConnectToApplicationParams); 121 new ConnectToApplicationParams);
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 const URLResponse* response = html_content_handler()->latest_response(); 172 const URLResponse* response = html_content_handler()->latest_response();
173 EXPECT_EQ("about:some_unrecognized_url", response->url); 173 EXPECT_EQ("about:some_unrecognized_url", response->url);
174 EXPECT_EQ(404u, response->status_code); 174 EXPECT_EQ(404u, response->status_code);
175 EXPECT_EQ("text/html", response->mime_type); 175 EXPECT_EQ("text/html", response->mime_type);
176 EXPECT_FALSE(response->body.is_valid()); 176 EXPECT_FALSE(response->body.is_valid());
177 } 177 }
178 178
179 } // namespace 179 } // namespace
180 } // namespace shell 180 } // namespace shell
181 } // namespace mojo 181 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/shell/connect_util.cc ('k') | mojo/shell/package_manager/content_handler_connection.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698