In https://github.com/electron/electron/commit/7613afe6d70eadd7446db921918dca086cd324c0 I had to disable the check that validates that the call is made on the right thread, because the check fails when the tests run.

Let's make sure the check doesn't fail and re-enable it. Or refactor so that the thread affinity is not required and remove the check.
atom/browser/api/atom_api_app.cc
ChildProcessLaunched(content::PROCESS_TYPE_RENDERER, host->GetHandle());
}
void App::RenderProcessDisconnected(base::ProcessId host_pid) {
  ChildProcessDisconnected(host_pid);
}
void App::ChildProcessLaunched(int process_type, base::ProcessHandle handle) {
  auto pid = base::GetProcId(handle);
#if defined(OS_MACOSX)
  std::unique_ptr<base::ProcessMetrics> metrics(
      base::ProcessMetrics::CreateProcessMetrics(
          handle, content::BrowserChildProcessHost::GetPortProvider()));
#else
  std::unique_ptr<base::ProcessMetrics> metrics(
      base::ProcessMetrics::CreateProcessMetrics(handle));
#endif
  std::unique_ptr<atom::ProcessMetric> process_metric(
      new atom::ProcessMetric(process_type, pid, std::move(metrics)));
  app_metrics_[pid] = std::move(process_metric);
}
void App::ChildProcessDisconnected(base::ProcessId pid) {
  app_metrics_.erase(pid);
}
base::FilePath App::GetAppPath() const {
  return app_path_;
}
void App::SetAppPath(const base::FilePath& app_path) {
  app_path_ = app_path;
}
base::FilePath App::GetPath(mate::Arguments* args, const std::string& name) {