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

Unified Diff: trunk/src/mojo/shell/shell_test_base_unittest.cc

Issue 443063003: Revert 287680 "mojo: terminate apps if the shell goes away" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 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
« no previous file with comments | « trunk/src/mojo/shell/context.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/mojo/shell/shell_test_base_unittest.cc
===================================================================
--- trunk/src/mojo/shell/shell_test_base_unittest.cc (revision 287751)
+++ trunk/src/mojo/shell/shell_test_base_unittest.cc (working copy)
@@ -135,7 +135,8 @@
// Tests that we can connect to a single service within a single app using
// a network based loader instead of local files.
-TEST_F(ShellTestBaseTest, ConnectBasicNetwork) {
+// TODO(tim): Bug 394477. NetworkService doesn't currently terminate.
+TEST_F(ShellTestBaseTest, DISABLED_ConnectBasicNetwork) {
InterfacePtr<TestService> service;
service.Bind(ConnectToServiceViaNetwork(
test_app_url(), TestService::Name_).Pass());
@@ -151,16 +152,14 @@
// magically exit when TestService is destroyed (unlike ConnectBasic).
// Tearing down the shell context will kill connections. The shell loop will
// exit as soon as no more apps are connected.
- // TODO(tim): crbug.com/392685. Calling this explicitly shouldn't be
- // necessary once the shell terminates if the primordial app exits, which
- // we could enforce here by resetting |service|.
- shell_context()->service_manager()->TerminateShellConnections();
- message_loop()->Run(); // Waits for all connections to die.
+ shell_context()->Shutdown();
+ message_loop()->Run();
}
// Tests that trying to connect to a service over network fails preoprly
// if the service doesn't exist.
-TEST_F(ShellTestBaseTest, ConnectInvalidServiceNetwork) {
+// TODO(tim): Bug 394477. NetworkService doesn't currently terminate.
+TEST_F(ShellTestBaseTest, DISABLED_ConnectInvalidServiceNetwork) {
InterfacePtr<TestService> test_service;
test_service.Bind(ConnectToServiceViaNetwork(
GURL("mojo:non_existent_service"), TestService::Name_).Pass());
@@ -171,11 +170,8 @@
message_loop()->Run();
EXPECT_TRUE(test_service.encountered_error());
- // TODO(tim): crbug.com/392685. Calling this explicitly shouldn't be
- // necessary once the shell terminates if the primordial app exits, which
- // we could enforce here by resetting |service|.
- shell_context()->service_manager()->TerminateShellConnections();
- message_loop()->Run(); // Waits for all connections to die.
+ shell_context()->Shutdown();
+ message_loop()->Run();
}
// Similar to ConnectBasic, but causes the app to instantiate multiple
« no previous file with comments | « trunk/src/mojo/shell/context.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698