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

Unified Diff: components/arc/test/fake_arc_bridge_instance.cc

Issue 1548833002: arc-bridge: Restart ARC instance on crash (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: Addressed more feedback Created 4 years, 11 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 | « components/arc/test/fake_arc_bridge_instance.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/arc/test/fake_arc_bridge_instance.cc
diff --git a/components/arc/test/fake_arc_bridge_instance.cc b/components/arc/test/fake_arc_bridge_instance.cc
index 4ee47cfdeb08a54def2d538caeed0c326c0c8139..cfa0737b40f245c38b3358d6df63e0cd7411a914 100644
--- a/components/arc/test/fake_arc_bridge_instance.cc
+++ b/components/arc/test/fake_arc_bridge_instance.cc
@@ -13,6 +13,13 @@ FakeArcBridgeInstance::~FakeArcBridgeInstance() {}
void FakeArcBridgeInstance::Init(ArcBridgeHostPtr host) {
host_ptr_ = std::move(host);
+ init_calls_++;
+}
+
+void FakeArcBridgeInstance::Unbind() {
+ host_ptr_.reset();
+ if (binding_.is_bound())
+ binding_.Close();
}
void FakeArcBridgeInstance::Bind(
@@ -20,4 +27,8 @@ void FakeArcBridgeInstance::Bind(
binding_.Bind(std::move(interface_request));
}
+void FakeArcBridgeInstance::WaitForInitCall() {
+ binding_.WaitForIncomingMethodCall();
+}
+
} // namespace arc
« no previous file with comments | « components/arc/test/fake_arc_bridge_instance.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698