mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 18:06:18 +03:00
Merge pull request #4316 from radarhere/docker_coverage
Added coverage for Docker GHA
This commit is contained in:
commit
cbabd87ff9
22
.github/workflows/test-docker.yml
vendored
22
.github/workflows/test-docker.yml
vendored
|
@ -42,3 +42,25 @@ jobs:
|
|||
# The Pillow user in the docker container is UID 1000
|
||||
sudo chown -R 1000 $GITHUB_WORKSPACE
|
||||
docker run -v $GITHUB_WORKSPACE:/Pillow pythonpillow/${{ matrix.docker }}:${{ matrix.dockerTag }}
|
||||
sudo chown -R runner $GITHUB_WORKSPACE
|
||||
|
||||
- name: After success
|
||||
if: success()
|
||||
run: |
|
||||
pip install wheel
|
||||
sudo apt-get install -qq ruby-dev
|
||||
PATH="$PATH:~/.local/bin"
|
||||
.travis/after_success.sh
|
||||
env:
|
||||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
|
||||
|
||||
- name: Prepare coverage token
|
||||
if: success() && github.repository == 'python-pillow/Pillow'
|
||||
run: cp .github/codecov-upstream.yml .codecov.yml
|
||||
|
||||
- name: Upload coverage
|
||||
if: success()
|
||||
uses: codecov/codecov-action@v1
|
||||
with:
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
name: ${{ matrix.docker }}
|
||||
|
|
|
@ -11,11 +11,12 @@ lcov --capture --directory . -b . --output-file coverage.info
|
|||
# filter to remove system headers
|
||||
lcov --remove coverage.info '/usr/*' -o coverage.filtered.info
|
||||
# convert to json
|
||||
gem install coveralls-lcov
|
||||
sudo gem install coveralls-lcov
|
||||
coveralls-lcov -v -n coverage.filtered.info > coverage.c.json
|
||||
|
||||
coverage report
|
||||
pip install codecov
|
||||
coverage report
|
||||
|
||||
pip install coveralls-merge
|
||||
coveralls-merge coverage.c.json
|
||||
if [[ $TRAVIS ]]; then
|
||||
|
|
Loading…
Reference in New Issue
Block a user