Skip to content

Commit

Permalink
build: Add tests to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
dshafik committed Apr 23, 2024
1 parent 2c9c0dd commit 0957009
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Tests

on:
- pull_request
- push

jobs:
tests:
name: Tests

runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup PHP with Xdebug
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
coverage: xdebug

- name: Install dependencies with composer
run: composer update --no-ansi --no-interaction --no-progress

- name: Run tests with phpunit/phpunit
run: vendor/bin/phpunit --coverage-clover=coverage.xml

- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

0 comments on commit 0957009

Please sign in to comment.