diff options
Diffstat (limited to '.forgejo/workflows')
| -rw-r--r-- | .forgejo/workflows/coverage.yml | 33 | ||||
| -rw-r--r-- | .forgejo/workflows/lint.yml | 25 |
2 files changed, 58 insertions, 0 deletions
diff --git a/.forgejo/workflows/coverage.yml b/.forgejo/workflows/coverage.yml new file mode 100644 index 0000000..cc464c8 --- /dev/null +++ b/.forgejo/workflows/coverage.yml @@ -0,0 +1,33 @@ +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] +name: Coverage +jobs: + coverage: + name: Coverage + runs-on: docker + container: + image: node:20 + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up php + uses: shivammathur/setup-php@v2 + with: + php-version: "8.3" + coverage: xdebug + + - name: Set-up Composer + uses: php-actions/composer@v6 + + - name: Run tests and collect coverage + run: ./vendor/bin/phpunit tests --coverage-clover coverage.xml tests + + - name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v3 + env: + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
\ No newline at end of file diff --git a/.forgejo/workflows/lint.yml b/.forgejo/workflows/lint.yml new file mode 100644 index 0000000..fad6051 --- /dev/null +++ b/.forgejo/workflows/lint.yml @@ -0,0 +1,25 @@ +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] +name: Lint +jobs: + lint: + name: Lint + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Set up php 8.3 + uses: shivammathur/setup-php@v2 + with: + php-version: "8.3" + + - name: Set-up Composer + uses: php-actions/composer@v6 + + - name: Run phpstan + run: ./vendor/bin/phpstan |
