-
Notifications
You must be signed in to change notification settings - Fork 1
61 lines (51 loc) · 1.6 KB
/
unit-tests.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
---
name: Unit-Tests
on:
push:
paths-ignore:
- 'docs/**'
pull_request:
branches: [master]
paths-ignore:
- 'docs/**'
workflow_call:
workflow_dispatch:
jobs:
lint_files:
uses: llaville/.github/.github/workflows/mega-linter.yml@master
with:
repository: ${{ github.repository }}
php-version: "8.2"
unit_tests:
needs: lint_files
name: Unit Tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- ubuntu-22.04
php:
- 8.2
- 8.3
steps:
- # https://github.com/actions/checkout
name: Checkout Code
uses: actions/checkout@v4
with:
token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }}
fetch-depth: 0
- # https://github.com/shivammathur/setup-php
name: Setup PHP runtime
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
ini-values: phar.readonly=0
- # https://github.com/ramsey/composer-install
name: Install Composer dependencies
uses: ramsey/composer-install@v3
with:
composer-options: "--prefer-dist"
- # https://github.com/sebastianbergmann/phpunit/tree/10.5
name: PHPUnit 10
run: composer tests:unit