Skip to content

Commit 8718a59

Browse files
cleanup selfdrive/test (commaai#23967)
* move test routes and test_models * move fingerprints * little more * remove that
1 parent fa4b434 commit 8718a59

File tree

9 files changed

+7
-9
lines changed

9 files changed

+7
-9
lines changed

.github/PULL_REQUEST_TEMPLATE/car_port.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ assignees: ''
99
**Checklist**
1010

1111
- [ ] added to README
12-
- [ ] test route added to [test_routes.py](https://github.com/commaai/openpilot/blob/master/selfdrive/test/test_models.py)
12+
- [ ] test route added to [routes.py](https://github.com/commaai/openpilot/blob/master/selfdrive/car/tests/routes.py)
1313
- [ ] route with openpilot:
1414
- [ ] route with stock system:
1515
- [ ] car harness used (if comma doesn't sell it, put N/A):

.github/workflows/selfdrive_tests.yaml

+2-3
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,6 @@ jobs:
245245
- name: Run unit tests
246246
run: |
247247
${{ env.RUN }} "scons -j$(nproc) --test && \
248-
coverage run selfdrive/test/test_fingerprints.py && \
249248
$UNIT_TEST common && \
250249
$UNIT_TEST opendbc/can && \
251250
$UNIT_TEST selfdrive/boardd && \
@@ -384,7 +383,7 @@ jobs:
384383
uses: actions/cache@v2
385384
with:
386385
path: /tmp/comma_download_cache
387-
key: car_models-${{ hashFiles('selfdrive/test/test_models.py', 'selfdrive/test/test_routes.py') }}-${{ matrix.job }}
386+
key: car_models-${{ hashFiles('selfdrive/car/tests/test_models.py', 'selfdrive/test/test_routes.py') }}-${{ matrix.job }}
388387
- name: Cache scons
389388
id: scons-cache
390389
# TODO: Change the version to the released version when https://github.com/actions/cache/pull/489 (or 571) is merged.
@@ -402,7 +401,7 @@ jobs:
402401
- name: Test car models
403402
run: |
404403
${{ env.RUN }} "scons -j$(nproc) --test && \
405-
FILEREADER_CACHE=1 coverage run -m pytest selfdrive/test/test_models.py && \
404+
FILEREADER_CACHE=1 coverage run -m pytest selfdrive/car/tests/test_models.py && \
406405
coverage xml && \
407406
chmod -R 777 /tmp/comma_download_cache"
408407
env:

release/files_common

-1
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,6 @@ selfdrive/thermald/fan_controller.py
341341
selfdrive/test/__init__.py
342342
selfdrive/test/helpers.py
343343
selfdrive/test/setup_device_ci.sh
344-
selfdrive/test/test_fingerprints.py
345344
selfdrive/test/test_onroad.py
346345

347346
selfdrive/ui/.gitignore

selfdrive/car/gm/interface.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=None):
4747

4848
# These cars have been put into dashcam only due to both a lack of users and test coverage.
4949
# These cars likely still work fine. Once a user confirms each car works and a test route is
50-
# added to selfdrive/test/test_routes, we can remove it from this list.
50+
# added to selfdrive/car/tests/routes.py, we can remove it from this list.
5151
ret.dashcamOnly = candidate in {CAR.CADILLAC_ATS, CAR.HOLDEN_ASTRA, CAR.MALIBU, CAR.BUICK_REGAL}
5252

5353
# Presence of a camera on the object bus is ok.

selfdrive/car/hyundai/interface.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def get_params(candidate, fingerprint=gen_empty_fingerprint(), car_fw=[]): # py
3232

3333
# These cars have been put into dashcam only due to both a lack of users and test coverage.
3434
# These cars likely still work fine. Once a user confirms each car works and a test route is
35-
# added to selfdrive/test/test_routes, we can remove it from this list.
35+
# added to selfdrive/car/tests/routes.py, we can remove it from this list.
3636
ret.dashcamOnly = candidate in {CAR.KIA_OPTIMA_H, CAR.ELANTRA_GT_I30}
3737

3838
ret.steerActuatorDelay = 0.1 # Default delay
File renamed without changes.
File renamed without changes.

selfdrive/test/test_models.py selfdrive/car/tests/test_models.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
from selfdrive.car.honda.values import CAR as HONDA, HONDA_BOSCH
1818
from selfdrive.car.hyundai.values import CAR as HYUNDAI
1919
from selfdrive.car.toyota.values import CAR as TOYOTA
20-
from selfdrive.test.test_routes import routes, non_tested_cars
20+
from selfdrive.car.tests.routes import routes, non_tested_cars
2121
from selfdrive.test.openpilotci import get_url
2222
from tools.lib.logreader import LogReader
2323

selfdrive/test/update_ci_routes.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import subprocess
44
from azure.storage.blob import BlockBlobService # pylint: disable=import-error
55

6-
from selfdrive.test.test_routes import routes as test_car_models_routes
6+
from selfdrive.car.tests.routes import routes as test_car_models_routes
77
from selfdrive.test.process_replay.test_processes import original_segments as replay_segments
88
from xx.chffr.lib import azureutil # pylint: disable=import-error
99
from xx.chffr.lib.storage import _DATA_ACCOUNT_PRODUCTION, _DATA_ACCOUNT_CI, _DATA_BUCKET_PRODUCTION # pylint: disable=import-error

0 commit comments

Comments
 (0)