Add "print" parameter to parse output from get-slot #259
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: review | |
on: [pull_request] | |
env: | |
cflags: -Werror | |
jobs: | |
checkpatch: | |
name: checkpatch review | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Calculate PR commits + 1' | |
run: echo "PR_FETCH_DEPTH=$(( ${{ github.event.pull_request.commits }} + 1 ))" >> $GITHUB_ENV | |
- uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
fetch-depth: ${{ env.PR_FETCH_DEPTH }} | |
- name: Run checkpatch review | |
uses: webispy/checkpatch-action@v9 | |
make: | |
name: Compilation test with gcc | |
strategy: | |
matrix: | |
gcc-version: [7, 8, 9, 10, 11, 12, 13] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: 'Add ubuntu repository and install dependencies' | |
run: tests/install_ubuntu_packages.sh ${{ matrix.gcc-version }} | |
- name: 'Generate compiling configurations' | |
run: . tests/build_configure.sh ${{ env.cflags }} | |
- name: 'Make' | |
run: CC=gcc-${{ matrix.gcc-version }} CXX=g++-${{ matrix.gcc-version }} && V=1 make -j$(nproc) | |
- name: 'Check public symbol visibility' | |
run: tests/check_symbol_visibility.sh | |
clangcompile: | |
name: Compilation test with clang | |
strategy: | |
matrix: | |
gcc-version: [12] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: 'Add ubuntu repository and install dependencies' | |
run: tests/install_ubuntu_packages.sh ${{ matrix.gcc-version }} | |
- name: 'Install clang' | |
run: sudo apt-get install clang | |
- name: 'Generate compiling configurations' | |
run: . tests/build_configure.sh ${{ env.cflags }} clang | |
- name: 'Make' | |
run: V=1 make -j$(nproc) | |
tests: | |
name: Run tests | |
strategy: | |
matrix: | |
gcc-version: [12] | |
python-version: ["3.7"] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: 'Add ubuntu repository and install dependencies' | |
run: tests/install_ubuntu_packages.sh ${{ matrix.gcc-version }} | |
- name: 'Generate compiling configurations' | |
run: . tests/build_configure.sh ${{ env.cflags }} | |
- name: 'Make' | |
run: CC=gcc-${{ matrix.gcc-version }} CXX=g++-${{ matrix.gcc-version }} && V=1 make -j$(nproc) | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install python dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install pytest | |
- name: Run tests using pytest | |
run: | | |
# Run only non-hardware dependent tests | |
pytest --ledctl-binary=src/ledctl/ledctl |