Pipe through exit statuses in AOS Run() methods

This makes it so that the sundry Run() methods can return exit statuses
when exited using the ExitHandle. This enables certain categories of
error-handling that were hard to do previously---in particular, this
enables future modifications to LogReader to propagate log reading
faults through this interface.

Change-Id: I238e7aa6b82dc3d7938630b2b0ab96eb30b573eb
Signed-off-by: James Kuszmaul <james.kuszmaul@bluerivertech.com>
diff --git a/aos/events/event_loop_param_test.h b/aos/events/event_loop_param_test.h
index f2b16c5..bbba5b7 100644
--- a/aos/events/event_loop_param_test.h
+++ b/aos/events/event_loop_param_test.h
@@ -68,7 +68,9 @@
   virtual std::unique_ptr<EventLoop> MakePrimary(std::string_view name) = 0;
 
   // Runs the loops until they quit.
-  virtual void Run() = 0;
+  virtual Result<void> Run() = 0;
+
+  virtual std::unique_ptr<ExitHandle> MakeExitHandle() = 0;
 
   // Quits the loops.
   virtual void Exit() = 0;
@@ -350,7 +352,11 @@
 
   void EnableNodes(std::string_view my_node) { factory_->EnableNodes(my_node); }
 
-  void Run() { return factory_->Run(); }
+  Result<void> Run() { return factory_->Run(); }
+
+  std::unique_ptr<ExitHandle> MakeExitHandle() {
+    return factory_->MakeExitHandle();
+  }
 
   void Exit() { return factory_->Exit(); }