Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2fe96325 authored by Hansong Zhang's avatar Hansong Zhang Committed by android-build-merger
Browse files

Gracefully shutdown SUT in cert

am: f8689a03

Change-Id: Idc2047ad66ea685babec3e3ed27c63cc71eacd4e
parents de53d2a3 f8689a03
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -61,6 +61,8 @@ class GdBaseTestClass(BaseTestClass):
            builtin=True)

    def teardown_class(self):
        self.unregister_controllers()
        self.rootcanal_process.send_signal(signal.SIGINT)
        self.rootcanal_process.wait()
        self.rootcanal_logs.close()
+1 −0
Original line number Diff line number Diff line
@@ -117,6 +117,7 @@ class GdDevice:
    def clean_up(self):
        self.grpc_channel.close()
        self.backing_process.send_signal(signal.SIGINT)
        self.backing_process.wait()
        self.backing_process_logs.close()

class GdDeviceLoggerAdapter(logging.LoggerAdapter):
+0 −1
Original line number Diff line number Diff line
@@ -69,7 +69,6 @@ int main(int argc, const char** argv) {
  auto wait_thread = std::thread([grpc_module] { grpc_module->RunGrpcLoop(); });
  wait_thread.join();

  grpc_module->StopServer();
  stack->ShutDown();
  delete stack;

+1 −0
Original line number Diff line number Diff line
@@ -50,6 +50,7 @@ void GrpcModule::StartServer(const std::string& address, int port) {
  builder.AddListeningPort(listening_port, ::grpc::InsecureServerCredentials());
  completion_queue_ = builder.AddCompletionQueue();
  server_ = builder.BuildAndStart();
  ASSERT(server_ != nullptr);

  for (const auto& facade : facades_) {
    facade->OnServerStarted(completion_queue_.get());