From a01a2ecc2411751a21cbf426f8256d09de9ae7f5 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Thu, 31 Dec 2020 15:01:38 -0800 Subject: [PATCH] disable cpu usage test until CAN replay hw is fixed --- Jenkinsfile | 2 +- selfdrive/test/test_cpu_usage.py | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index f8ce1f3d..e8f073ba 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -114,7 +114,7 @@ pipeline { ["build", "SCONS_CACHE=1 scons -j4"], ["test athena", "nosetests -s selfdrive/athena/tests/test_athenad_old.py"], ["test manager", "python selfdrive/test/test_manager.py"], - ["test cpu usage", "cd selfdrive/test/ && ./test_cpu_usage.py"], + //["test cpu usage", "cd selfdrive/test/ && ./test_cpu_usage.py"], ["build devel", "cd release && CI_PUSH=${env.CI_PUSH} ./build_devel.sh"], ["test car interfaces", "cd selfdrive/car/tests/ && ./test_car_interfaces.py"], ["test spinner build", "cd selfdrive/ui/spinner && make clean && make"], diff --git a/selfdrive/test/test_cpu_usage.py b/selfdrive/test/test_cpu_usage.py index b6147d17..9e472dad 100755 --- a/selfdrive/test/test_cpu_usage.py +++ b/selfdrive/test/test_cpu_usage.py @@ -71,14 +71,13 @@ def test_cpu_usage(): manager_proc = subprocess.Popen(["python", manager_path]) try: proc_sock = messaging.sub_sock('procLog', conflate=True, timeout=2000) - cs_sock = messaging.sub_sock('controlsState', conflate=True) + cs_sock = messaging.sub_sock('controlsState') # wait until everything's started + msg = None start_time = time.monotonic() - while time.monotonic() - start_time < 240: - msg = messaging.recv_sock(cs_sock, wait=True) - if msg is not None: - break + while msg is None and time.monotonic() - start_time < 240: + msg = messaging.recv_sock(cs_sock) # take first sample time.sleep(15)