Index: third_party/mojo/src/mojo/public/cpp/application/lib/application_test_base.cc |
diff --git a/third_party/mojo/src/mojo/public/cpp/application/lib/application_test_base.cc b/third_party/mojo/src/mojo/public/cpp/application/lib/application_test_base.cc |
index 406c826d4de16d0001cc78c976c55e66ba31aa18..af6e13a29110eccb58b688b4efa0e799e85612d5 100644 |
--- a/third_party/mojo/src/mojo/public/cpp/application/lib/application_test_base.cc |
+++ b/third_party/mojo/src/mojo/public/cpp/application/lib/application_test_base.cc |
@@ -17,6 +17,9 @@ namespace { |
// Share the application command-line arguments with multiple application tests. |
Array<String> g_args; |
+// Share the application URL with multiple application tests. |
+String g_url; |
+ |
// Application request handle passed from the shell in MojoMain, stored in |
// between SetUp()/TearDown() so we can (re-)intialize new ApplicationImpls. |
InterfaceRequest<Application> g_application_request; |
@@ -51,6 +54,7 @@ class ShellAndArgumentGrabber : public Application { |
Array<String> args, |
const mojo::String& url) override { |
*args_ = args.Pass(); |
+ g_url = url; |
g_application_request = binding_.Unbind(); |
g_shell = shell.Pass(); |
} |
@@ -140,7 +144,7 @@ void ApplicationTestBase::SetUp() { |
g_application_request.Pass()); |
// Fake application initialization with the given command line arguments. |
- application_impl_->Initialize(g_shell.Pass(), g_args.Clone(), ""); |
+ application_impl_->Initialize(g_shell.Pass(), g_args.Clone(), g_url); |
} |
void ApplicationTestBase::TearDown() { |