Skip to content

Commit

Permalink
fix workflow and coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
zeriyoshi committed Aug 21, 2024
1 parent ad54cb0 commit 7d42ed9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/octocov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@ coverage:
- ../lcov.info
acceptable: current >= 60%
testExecutionTime:
acceptable: current <= 5min && diff < 5min
if: false
comment:
if: is_pull_request
diff:
datastores:
- artifact://${GITHUB_REPOSITORY}
comment:
if: is_pull_request
report:
if: is_default_branch
datastores:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Coverage
permissions:
contents: write
pull-requests: write
on:
push:
branches:
Expand Down Expand Up @@ -30,7 +31,7 @@ jobs:
docker compose build --pull --no-cache --build-arg PLATFORM="linux/amd64" --build-arg IMAGE="php" --build-arg TAG="${{ matrix.version }}-${{ matrix.type }}-${{ matrix.distro }}"
- name: Test with gcov
run: |
docker compose run -v "$(pwd)/ext:/ext" --rm shell /bin/sh -c 'pskel test gcov && lcov --capture --directory "/ext" --output-file "/ext/lcov.info" --exclude "Zend/*" --exclude "third_party/*"'
docker compose run -v "$(pwd)/ext:/ext" --rm shell /bin/sh -c 'pskel test gcov && lcov --capture --directory "/ext" --output-file "/ext/lcov.info" --exclude "/usr/local/include/*" --exclude "third_party/*" && lcov --list "/ext/lcov.info"'
- name: Upload coverage to artifact
uses: actions/upload-artifact@v4
with:
Expand Down Expand Up @@ -59,4 +60,5 @@ jobs:
- name: Report coverage
uses: k1LoW/octocov-action@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
config: .github/octocov.yml

0 comments on commit 7d42ed9

Please sign in to comment.