Skip to content

Commit b79b195

Browse files
committed
tools
1 parent 11a4aba commit b79b195

2 files changed

Lines changed: 21 additions & 9 deletions

File tree

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
1-
name: SonarCloud
1+
name: SonarQube Cloud Scan
22
on: [push]
33
jobs:
44
sonarcloud:
55
runs-on: ${{ matrix.os }}
66
strategy:
77
matrix:
8-
os: [ubuntu-latest]
8+
os: [ubuntu-24.04]
99
php: ["8.4"]
1010
env:
1111
tools: composer
1212
ini-values: default_charset='UTF-8'
13-
key: cache-1690242875644
1413
name: PHP ${{ matrix.php }} test on ${{ matrix.os }}
1514
steps:
1615
- name: Checkout
@@ -46,8 +45,8 @@ jobs:
4645
run: |
4746
sed -i 's@'$GITHUB_WORKSPACE'@/github/workspace@g' clover.xml
4847
sed -i 's@'$GITHUB_WORKSPACE'@/github/workspace@g' junit.xml
49-
- name: SonarCloud scan
50-
uses: SonarSource/sonarcloud-github-action@master
48+
- name: SonarQube cloud scan
49+
uses: SonarSource/sonarqube-scan-action@v5
5150
env:
5251
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5352
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

.github/workflows/test.yml

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,19 @@ jobs:
55
runs-on: ${{ matrix.os }}
66
strategy:
77
matrix:
8-
os: [ubuntu-latest]
8+
os: [ubuntu-24.04]
99
php: ["8.1", "8.2", "8.3", "8.4"]
10+
include:
11+
- php: "8.1"
12+
infection: "0.29.9"
13+
- php: "8.2"
14+
infection: "latest"
15+
- php: "8.3"
16+
infection: "latest"
17+
- php: "8.4"
18+
infection: "latest"
1019
env:
11-
tools: composer, phpstan, infection
20+
tools: composer, phpstan, infection:${{ matrix.infection }}
1221
ini-values: default_charset='UTF-8'
1322
name: PHP ${{ matrix.php }} test on ${{ matrix.os }}
1423
steps:
@@ -43,7 +52,11 @@ jobs:
4352
- name: Tests (PHPUnit)
4453
run: vendor/bin/phpunit --coverage-xml=build/logs/xml-coverage --log-junit=build/logs/junit.xml
4554
- name: Mutation testing (Infection)
46-
if: matrix.php != '8.1'
4755
env:
4856
INFECTION_BADGE_API_KEY: ${{ secrets.INFECTION_BADGE_API_KEY }}
49-
run: infection --coverage=build/logs --min-covered-msi=90 --threads=$(nproc) --logger-github --only-covered
57+
run: |
58+
if [ "${{ matrix.php }}" = "8.1" ]; then
59+
infection --coverage=build/logs --min-covered-msi=90 --threads=$(nproc) --logger-github --only-covered
60+
else
61+
infection --coverage=build/logs --min-covered-msi=90 --threads=$(nproc) --logger-github
62+
fi

0 commit comments

Comments
 (0)