Skip to content

Delete extras/kicad/V2/smartcar_control_v2.0.kicad_pro #55

Delete extras/kicad/V2/smartcar_control_v2.0.kicad_pro

Delete extras/kicad/V2/smartcar_control_v2.0.kicad_pro #55

Workflow file for this run

name: Tests
on: [push, pull_request]
jobs:
run-unit-tests-and-static-analysis:
runs-on: ubuntu-20.04
strategy:
matrix:
compiler:
- cc: gcc-10
cxx: g++-10
- cc: clang-10
cxx: clang++-10
env:
CC: ${{ matrix.compiler.cc }}
CXX: ${{ matrix.compiler.cxx }}
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # Shallow clones should be disabled for Sonarqube
- name: Get dependencies
run: |
sudo apt-get install -y ${{ matrix.compiler.cc }}
sudo apt-get install -y ${{ matrix.compiler.cxx }}
sudo apt-get install -y lcov cppcheck clang-tidy-8
- name: Build & run unit tests
run: bash test/build_and_run_ut.sh
- name: Run static analysis (cppcheck)
run: |
cppcheck --std=c++11 --enable=performance,portability,information --quiet --error-exitcode=1 src/
- name: Run clang-tidy
if: matrix.compiler.cc == 'clang-10'
run: |
run-clang-tidy-8 \
-p=test/build \
-j$(nproc) \
-header-filter=src/* \
files src/* \
-export-fixes clang-tidy-fixes.yaml
- name: Run clang-tidy-pr-comments action
uses: platisd/clang-tidy-pr-comments@master
if: matrix.compiler.cc == 'clang-10'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
clang_tidy_fixes: clang-tidy-fixes.yaml
request_changes: true
- name: Get coverage report (only for GCC)
if: matrix.compiler.cc == 'gcc-10'
run: |
bash run_coverage.sh
bash <(curl -s https://codecov.io/bash) -s coverage-reports || echo "Codecov did not collect coverage reports"