Skip to content

[CI/CD] No "coverage" file here #510

[CI/CD] No "coverage" file here

[CI/CD] No "coverage" file here #510

Workflow file for this run

name: Regression tests
on:
push:
paths:
- '**.py'
- 'src/*_do'
- 'tests/**'
- '.github/workflows/pythonapp.yml'
pull_request:
paths:
- '**.py'
- 'src/*_do'
- 'tests/**'
- '.github/workflows/pythonapp.yml'
jobs:
test:
# continue-on-error: true
strategy:
fail-fast: false
matrix:
ki_release: [ki5, ki6, ki7, ki8]
w_tests: [interposer, no_interposer]
runs-on: ubuntu-latest
container: ghcr.io/inti-cmnb/kicad_auto_test:${{ matrix.ki_release }}
steps:
- uses: actions/checkout@v4
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings.
flake8 . --count --exit-zero --statistics
- name: Test ${{ matrix.ki_release }}
shell: bash
run: |
if [ "${{ matrix.w_tests }}" == 'no_interposer' ]; then export KIAUTO_INTERPOSER_DISABLE=1; fi
make test_server_${{ matrix.ki_release }}
- name: Store results
if: ${{ always() }}
uses: actions/upload-artifact@v4
with:
name: Test_Output_${{ matrix.ki_release }}_${{ matrix.w_tests }}
path: output
# Coveralls reporter v0.6.10 support for Python is broken, the action uses the latest available
# - name: Upload Coverage
# uses: coverallsapp/github-action@v2
# with:
# flag-name: ${{ matrix.ki_release }}_${{ matrix.w_tests }}
# parallel: true
# github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Upload Coverage
env:
COVERALLS_DEBUG: true
COVERALLS_FLAG_NAME: ${{ matrix.ki_release }}_${{ matrix.w_tests }}
COVERALLS_PARALLEL: true
COVERALLS_ENDPOINT: https://coveralls.io
# COVERALLS_GIT_BRANCH: ${{ inputs.git-branch }}
# COVERALLS_GIT_COMMIT: ${{ inputs.git-commit }}
COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# COVERALLS_COMPARE_REF: ${{ inputs.compare-ref }}
# COVERALLS_COMPARE_SHA: ${{ inputs.compare-sha }}
COVERALLS_SOURCE_HEADER: github-action
run: |
ls -la .coverage*
mkdir -p ~/bin/
echo ~/bin >> $GITHUB_PATH
ln -s `which python3-coverage` /usr/bin/coverage
python3-coverage --version
coverage --version
export CURDIR=`pwd`
cd ~/bin/
curl -sLO https://github.com/coverallsapp/coverage-reporter/releases/download/v0.6.9/coveralls-linux.tar.gz
curl -sLO https://github.com/coverallsapp/coverage-reporter/releases/download/v0.6.9/coveralls-checksums.txt
# curl -sLO https://github.com/coverallsapp/coverage-reporter/releases/latest/download/coveralls-linux.tar.gz
# curl -sLO https://github.com/coverallsapp/coverage-reporter/releases/latest/download/coveralls-checksums.txt
cat coveralls-checksums.txt | grep coveralls-linux.tar.gz | sha256sum --check
tar -xzf coveralls-linux.tar.gz
rm coveralls-checksums.txt
ls -la ~/bin/
cd ${CURDIR}
~/bin/coveralls report --debug --format python .coverage
coveralls:
name: Finish Coveralls
needs: test
runs-on: ubuntu-latest
steps:
- name: Finished
env:
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
run: |
curl -k https://coveralls.io/webhook?repo_token=$COVERALLS_REPO_TOKEN -d "payload[build_num]="$GITHUB_RUN_ID"&payload[status]=done"