mirror of
https://github.com/dragonpilot/dragonpilot.git
synced 2026-06-26 08:22:05 +08:00
tizi tests in jenkins (#27810)
* add * mv there for now * mv * single panda * move into parallel * longer timeout for dfu --------- Co-authored-by: Comma Device <device@comma.ai>
This commit is contained in:
Vendored
+14
@@ -125,6 +125,20 @@ pipeline {
|
||||
}
|
||||
*/
|
||||
|
||||
stage('tizi-tests') {
|
||||
agent { docker { image 'ghcr.io/commaai/alpine-ssh'; args '--user=root' } }
|
||||
steps {
|
||||
phone_steps("tizi", [
|
||||
["build openpilot", "cd selfdrive/manager && ./build.py"],
|
||||
["test boardd loopback", "SINGLE_PANDA=1 python selfdrive/boardd/tests/test_boardd_loopback.py"],
|
||||
["test pandad", "python selfdrive/boardd/tests/test_pandad.py"],
|
||||
["test sensord", "cd system/sensord/tests && python -m unittest test_sensord.py"],
|
||||
["test camerad", "python system/camerad/test/test_camerad.py"],
|
||||
["test exposure", "python system/camerad/test/test_exposure.py"],
|
||||
])
|
||||
}
|
||||
}
|
||||
|
||||
stage('build') {
|
||||
agent { docker { image 'ghcr.io/commaai/alpine-ssh'; args '--user=root' } }
|
||||
environment {
|
||||
|
||||
@@ -40,8 +40,9 @@ class TestBoardd(unittest.TestCase):
|
||||
sm.update(1000)
|
||||
|
||||
num_pandas = len(sm['pandaStates'])
|
||||
if TICI:
|
||||
self.assertGreater(num_pandas, 1, "connect another panda for multipanda tests")
|
||||
expected_pandas = 2 if TICI and "SINGLE_PANDA" not in os.environ else 1
|
||||
self.assertEqual(num_pandas, expected_pandas, "connected pandas ({num_pandas}) doesn't match expected panda count ({expected_pandas}). \
|
||||
connect another panda for multipanda tests.")
|
||||
|
||||
# boardd blocks on CarVin and CarParams
|
||||
cp = car.CarParams.new_message()
|
||||
|
||||
@@ -14,9 +14,9 @@ class TestPandad(unittest.TestCase):
|
||||
def tearDown(self):
|
||||
managed_processes['pandad'].stop()
|
||||
|
||||
def _wait_for_boardd(self):
|
||||
def _wait_for_boardd(self, timeout=30):
|
||||
sm = messaging.SubMaster(['peripheralState'])
|
||||
for _ in range(30):
|
||||
for _ in range(timeout):
|
||||
sm.update(1000)
|
||||
if sm.updated['peripheralState']:
|
||||
break
|
||||
@@ -30,7 +30,7 @@ class TestPandad(unittest.TestCase):
|
||||
time.sleep(1)
|
||||
|
||||
managed_processes['pandad'].start()
|
||||
self._wait_for_boardd()
|
||||
self._wait_for_boardd(60)
|
||||
|
||||
@phone_only
|
||||
def test_in_bootstub(self):
|
||||
|
||||
Reference in New Issue
Block a user