name: Validate on: push: branches: [main, develop] pull_request: branches: [main, develop] jobs: build-and-test: runs-on: ubuntu-latest container: image: ubuntu:24.04 steps: - name: Install build dependencies run: | apt-get update apt-get install -y --no-install-recommends \ build-essential gcc make \ cppcheck \ lcov \ python3 python3-pip \ git ca-certificates pip3 install --break-system-packages doorstop || true - name: Checkout uses: actions/checkout@v4 - name: Static Analysis (Cppcheck) run: make static - name: MISRA Check run: | make misra || echo "MISRA findings present (Demo macht den Check non-failing)" - name: Build + Unit Tests run: make test - name: Coverage Report run: make coverage - name: Doorstop Check run: | if [ -f .doorstop.yml ]; then doorstop || echo "Doorstop not fully configured" fi - name: Upload Coverage HTML uses: actions/upload-artifact@v3 if: always() with: name: coverage-html path: build/coverage-html/ - name: Upload Cppcheck Report uses: actions/upload-artifact@v3 if: always() with: name: cppcheck-report path: build/cppcheck-report.xml