Skip to content

Real python package #4090

Real python package

Real python package #4090

Workflow file for this run

name: tests
on: [push, pull_request]
jobs:
unit_tests:
name: unit tests
runs-on: ubuntu-24.04
strategy:
matrix:
flags: ['', '--asan', '--ubsan']
backend: ['MSGQ', 'ZMQ']
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Building msgq
run: |
export BUILD_TESTS=1
scripts/install_dependencies.sh
pip3 install --break-system-packages .[dev]
- name: Python tests
run: ${{ matrix.backend }}=1 pytest --continue-on-collection-errors --cov --cov-report=xml --cov-append
- name: C++ tests
run: |
export ${{ matrix.backend }}=1
scons ${{ matrix.flags }} -j$(nproc)
msgq/test_runner
msgq/visionipc/test_runner
- name: Upload coverage
run: "bash <(curl -s https://codecov.io/bash) -v -F unit_tests_${{ matrix.backend }}"
static_analysis:
name: static analysis
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v3
- name: Building msgq
run: |
scripts/install_dependencies.sh
pip3 install --break-system-packages .[dev]
- name: Static analysis
# TODO: a package pre-commit installs has a warning, remove the unset once that's fixed
run: unset PYTHONWARNINGS && pre-commit run --all