-
-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (37 loc) · 1.33 KB
/
all_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
name: "All Tests"
on:
pull_request:
push:
jobs:
test:
name: "Run all checks for all supported PHP versions"
runs-on: "ubuntu-22.04"
strategy:
fail-fast: false
matrix:
php-version:
- "8.0"
- "8.1"
- "8.2"
- "8.3"
steps:
- name: "Checkout"
uses: "actions/checkout@v4"
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "${{ matrix.php-version }}"
tools: composer
- name: Get composer cache directory
id: composercache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache dependencies
uses: actions/cache@v4
with:
path: ${{ steps.composercache.outputs.dir }}
key: "php-${{ matrix.php-version }}-${{ hashFiles('**/composer.lock') }}"
restore-keys: "php-${{ matrix.php-version }}-${{ hashFiles('**/composer.lock') }}"
- name: "Install composer dependencies"
run: "composer install --no-interaction --no-progress"
- name: "Run tests"
run: "composer tests"