|
|
@ -6,9 +6,9 @@ from parameterized import parameterized |
|
|
|
|
|
|
|
|
|
|
|
from cereal import car |
|
|
|
from cereal import car |
|
|
|
from selfdrive.car import gen_empty_fingerprint |
|
|
|
from selfdrive.car import gen_empty_fingerprint |
|
|
|
from selfdrive.car.fingerprints import all_known_cars |
|
|
|
|
|
|
|
from selfdrive.car.car_helpers import interfaces |
|
|
|
from selfdrive.car.car_helpers import interfaces |
|
|
|
from selfdrive.car.fingerprints import _FINGERPRINTS as FINGERPRINTS |
|
|
|
from selfdrive.car.fingerprints import _FINGERPRINTS as FINGERPRINTS, all_known_cars |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class TestCarInterfaces(unittest.TestCase): |
|
|
|
class TestCarInterfaces(unittest.TestCase): |
|
|
|
|
|
|
|
|
|
|
@ -51,7 +51,7 @@ class TestCarInterfaces(unittest.TestCase): |
|
|
|
|
|
|
|
|
|
|
|
elif tune.which() == 'torque': |
|
|
|
elif tune.which() == 'torque': |
|
|
|
self.assertTrue(not math.isnan(tune.torque.kf) and tune.torque.kf > 0) |
|
|
|
self.assertTrue(not math.isnan(tune.torque.kf) and tune.torque.kf > 0) |
|
|
|
self.assertTrue(not math.isnan(tune.torque.friction)) |
|
|
|
self.assertTrue(not math.isnan(tune.torque.friction) and tune.torque.friction > 0) |
|
|
|
|
|
|
|
|
|
|
|
elif tune.which() == 'indi': |
|
|
|
elif tune.which() == 'indi': |
|
|
|
self.assertTrue(len(tune.indi.outerLoopGainV)) |
|
|
|
self.assertTrue(len(tune.indi.outerLoopGainV)) |
|
|
|