Ensure Athena is not running during onroad tests (#21088)

* ensure Athena is not running during onroad tests

* do from unittest
pull/21092/head
Willem Melching 4 years ago committed by GitHub
parent 4a24d389c4
commit 6fe7fcd6e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      selfdrive/test/test_onroad.py

@ -12,6 +12,7 @@ import cereal.messaging as messaging
from cereal.services import service_list
from common.basedir import BASEDIR
from common.timeout import Timeout
from common.params import Params
from selfdrive.hardware import TICI
from selfdrive.loggerd.config import ROOT
from selfdrive.test.helpers import set_params_enabled
@ -98,6 +99,11 @@ class TestOnroad(unittest.TestCase):
os.environ['FINGERPRINT'] = "TOYOTA COROLLA TSS2 2019"
set_params_enabled()
# Make sure athena isn't running
Params().delete("DongleId")
Params().delete("AthenadPid")
subprocess.check_call(["pkill", "-9", "-f", "athena"])
logger_root = Path(ROOT)
initial_segments = set()
if logger_root.exists():

Loading…
Cancel
Save