[3.8] bpo-36670: regrtest bug fixes (GH-16537) by miss-islington · Pull Request #16538 · python/cpython

@vstinner @miss-islington

* Fix TestWorkerProcess.__repr__(): start_time is only valid
  if _popen is not None.
* Fix _kill(): don't set _killed to True if _popen is None.
* _run_process(): only set _killed to False after calling
  run_test_in_subprocess().
(cherry picked from commit 2ea71a0)

Co-authored-by: Victor Stinner <vstinner@python.org>

vstinner