Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,13 @@ jobs:
> infection.json5
cat infection.json5 | jq

- name: "Cache Result cache"
uses: actions/cache@v4
- name: "Determine default branch"
id: default-branch
run: |
echo "name=$(git remote show origin | sed -n '/HEAD branch/s/.*: //p')" >> $GITHUB_OUTPUT

- name: "Restore result cache"
uses: actions/cache/restore@v4
with:
path: ./tmp
key: "result-cache-v1-${{ matrix.php-version }}-${{ github.run_id }}"
Expand All @@ -271,13 +276,20 @@ jobs:

- name: "Run infection"
run: |
git fetch --depth=1 origin $GITHUB_BASE_REF
git fetch --depth=1 origin ${{ steps.default-branch.outputs.name }}
infection \
--git-diff-base=origin/$GITHUB_BASE_REF \
--git-diff-base=origin/${{ steps.default-branch.outputs.name }} \
--git-diff-lines \
--ignore-msi-with-no-mutations \
--min-msi=100 \
--min-covered-msi=100 \
--log-verbosity=all \
--debug \
--logger-text=php://stdout

- name: "Save result cache"
uses: actions/cache/save@v4
if: ${{ !cancelled() }}
with:
path: ./tmp
key: "result-cache-v1-${{ matrix.php-version }}-${{ github.run_id }}"
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ cs-fix:

.PHONY: phpstan
phpstan:
php vendor/bin/phpstan analyse -l 8 -c phpstan.neon src tests
php vendor/bin/phpstan analyse -c phpstan.neon src tests

.PHONY: phpstan-generate-baseline
phpstan-generate-baseline:
php vendor/bin/phpstan analyse -l 8 -c phpstan.neon src tests -b phpstan-baseline.neon
php vendor/bin/phpstan analyse -c phpstan.neon src tests -b phpstan-baseline.neon
1 change: 1 addition & 0 deletions phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ includes:
- phpstan-baseline.neon

parameters:
level: 8
reportUnmatchedIgnoredErrors: false

resultCachePath: tmp/resultCache.php
Expand Down
Loading