From 6ec00f5ee2d07ca0b1b98cf4dc1f19487c08a98f Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Tue, 15 Aug 2023 20:01:33 -0700 Subject: [PATCH] test_models: more typing (#29420) * not type checked, but we set this in test_car_model * type this --- selfdrive/car/tests/routes.py | 2 +- selfdrive/car/tests/test_models.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/selfdrive/car/tests/routes.py b/selfdrive/car/tests/routes.py index 056a3484a7..857ba8e4f4 100644 --- a/selfdrive/car/tests/routes.py +++ b/selfdrive/car/tests/routes.py @@ -33,7 +33,7 @@ non_tested_cars = [ class CarTestRoute(NamedTuple): route: str - car_model: str + car_model: Optional[str] segment: Optional[int] = None diff --git a/selfdrive/car/tests/test_models.py b/selfdrive/car/tests/test_models.py index 195b537378..b11b067350 100755 --- a/selfdrive/car/tests/test_models.py +++ b/selfdrive/car/tests/test_models.py @@ -66,9 +66,9 @@ SKIP_ENV_VAR = "SKIP_LONG_TESTS" class TestCarModelBase(unittest.TestCase): - car_model = None - test_route = None - ci = True + car_model: Optional[str] = None + test_route: Optional[CarTestRoute] = None + ci: bool = True @unittest.skipIf(SKIP_ENV_VAR in os.environ, f"Long running test skipped. Unset {SKIP_ENV_VAR} to run") @classmethod