openpilot/run_docker_tests.sh

25 lines
1.2 KiB
Bash
Raw Normal View History

2020-01-17 11:22:00 -07:00
#!/bin/bash
set -e
2020-06-04 15:27:54 -06:00
# NOTE: this may be not an up-to-date list of tests and checks, see .github/workflows/test.yaml for the current list of tests
2020-01-17 11:22:00 -07:00
SETUP="cd /tmp/openpilot && "
2020-05-20 01:00:13 -06:00
BUILD="cd /tmp/openpilot && scons -c && scons -j$(nproc) && "
RUN="docker run --shm-size 1G --rm tmppilot /bin/bash -c"
2020-01-17 11:22:00 -07:00
docker build -t tmppilot -f Dockerfile.openpilot .
2020-06-04 15:27:54 -06:00
$RUN "$SETUP cd selfdrive/test/ && ./test_fingerprints.py"
$RUN "$SETUP git init && git add -A && pre-commit run --all"
2020-05-20 01:00:13 -06:00
$RUN "$BUILD python -m unittest discover common && \
python -m unittest discover opendbc/can && \
python -m unittest discover selfdrive/boardd && \
python -m unittest discover selfdrive/controls && \
python -m unittest discover selfdrive/loggerd && \
python -m unittest discover selfdrive/car && \
python -m unittest discover selfdrive/locationd && \
python -m unittest discover selfdrive/athena"
$RUN "$BUILD cd /tmp/openpilot/selfdrive/test/longitudinal_maneuvers && OPTEST=1 ./test_longitudinal.py"
$RUN "$BUILD cd /tmp/openpilot/selfdrive/test/process_replay/ && ./test_processes.py"
$RUN "$BUILD mkdir -p /data/params && cd /tmp/openpilot/selfdrive/test/ && ./test_car_models.py"