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

Unified Diff: ios/web/public/test/http_server_util.mm

Issue 2285773002: Ability to add ResponseProvider (Closed)
Patch Set: Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: ios/web/public/test/http_server_util.mm
diff --git a/ios/web/public/test/http_server_util.mm b/ios/web/public/test/http_server_util.mm
index 7be13c2a50c12c11170315163088e389e1fc7c98..7b032bcc81613bfa3d15caddaf9bd50b048687b4 100644
--- a/ios/web/public/test/http_server_util.mm
+++ b/ios/web/public/test/http_server_util.mm
@@ -31,5 +31,11 @@ void SetUpHttpServer(std::unique_ptr<web::ResponseProvider> provider) {
server.AddResponseProvider(std::move(provider));
}
+void AddResponseProvider(std::unique_ptr<web::ResponseProvider> provider) {
+ web::test::HttpServer& server = web::test::HttpServer::GetSharedInstance();
+ DCHECK(server.IsRunning());
+ server.AddResponseProvider(std::move(provider));
+}
+
} // namespace test
} // namespace web
« ios/web/public/test/http_server_util.h ('K') | « ios/web/public/test/http_server_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698