Skip to content

Commit 630a9d0

Browse files
committed
Add SonarQube Cloud integration with PHPUnit coverage reporting
1 parent 24018c1 commit 630a9d0

File tree

75 files changed

+8227
-18
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+8227
-18
lines changed

.github/workflows/ci.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: CI
2+
3+
on:
4+
- pull_request
5+
- push
6+
7+
jobs:
8+
tests:
9+
name: Tests
10+
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v3
16+
with:
17+
fetch-depth: 0
18+
19+
- name: Setup PHP with Xdebug
20+
uses: shivammathur/setup-php@v2
21+
with:
22+
php-version: '8.2'
23+
coverage: xdebug
24+
extensions: pgsql, pdo_pgsql
25+
26+
- name: Install dependencies with composer
27+
run: composer update --no-ansi --no-interaction --no-progress
28+
29+
- name: Run tests with phpunit/phpunit
30+
run: vendor/bin/phpunit --coverage-clover=coverage.xml
31+
32+
- name: SonarQube Scan
33+
uses: SonarSource/sonarqube-scan-action@v6
34+
env:
35+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
36+
SONAR_HOST_URL: https://sonarcloud.io

0 commit comments

Comments
 (0)