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

Issue 315863002: Fix destruction tests. (Closed)

Created:
6 years, 6 months ago by Ben Goodger (Google)
Modified:
6 years, 6 months ago
Reviewers:
DaveMoore, sky
CC:
chromium-reviews, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, darin (slow to review), ben+mojo_chromium.org
Visibility:
Public.

Description

Fix destruction tests. I had to find a way to destroy a ViewManagerConnection from the client lib. In the new world, the ViewManagerSynchronizer is the InterfaceImpl, and lifetime of all other client objects hangs off it. ViewManagerSynchronizer is owned by the ServiceConnector which is owned by the Application object, so I had to find a way to delete that. In the test, I simply reset the ServiceLoader by URL. This tears down the synchronizer & corresponding ViewManagerConnection, triggering the correct notifications. Dave, I had to add a NULL check in the service manager code because it hadn't considered there could be a NULL loader for a URL. LMK if you have a different idea. R=davemoore@chromium.org, sky@chromium.org http://crbug.com/365012 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=274841

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+60 lines, -56 lines) Patch
M mojo/service_manager/service_manager.cc View 1 chunk +3 lines, -1 line 0 comments Download
M mojo/services/public/cpp/view_manager/lib/view_manager_synchronizer.cc View 1 chunk +4 lines, -1 line 0 comments Download
M mojo/services/public/cpp/view_manager/tests/view_manager_unittest.cc View 6 chunks +53 lines, -54 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Ben Goodger (Google)
6 years, 6 months ago (2014-06-04 05:16:02 UTC) #1
sky
LGTM
6 years, 6 months ago (2014-06-04 14:52:59 UTC) #2
DaveMoore
LGTM
6 years, 6 months ago (2014-06-04 15:35:46 UTC) #3
Ben Goodger (Google)
6 years, 6 months ago (2014-06-04 15:49:51 UTC) #4
Message was sent while issue was closed.
Committed patchset #1 manually as r274841 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698