-
-
Notifications
You must be signed in to change notification settings - Fork 187
84 lines (80 loc) · 2.7 KB
/
Copy pathquality.yml
File metadata and controls
84 lines (80 loc) · 2.7 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: Code Quality
on:
push:
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
phpstan:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: [8.5, 8.4, 8.3]
laravel: [13.*, 12.*, 11.*]
dependency-version: [prefer-stable]
include:
- laravel: 13.*
testbench: 11.*
- laravel: 12.*
testbench: 10.*
- laravel: 11.*
testbench: 9.*
- php: 8.5
pest: ^4.0
pest-plugin-laravel: ^4.0
- php: 8.4
pest: ^4.0
pest-plugin-laravel: ^4.0
- php: 8.3
pest: ^4.0
pest-plugin-laravel: ^4.0
name: PHP${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }}
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Cache Composer dependencies
uses: actions/cache@v5
with:
path: ~/.composer/cache/files
key: composer-${{ matrix.php }}-${{ matrix.laravel }}-${{ hashFiles('composer.json') }}
restore-keys: |
composer-${{ matrix.php }}-${{ matrix.laravel }}-
composer-${{ matrix.php }}-
- name: Cache PHPStan result
uses: actions/cache@v5
with:
path: /tmp/phpstan
key: phpstan-${{ matrix.php }}-${{ matrix.laravel }}-${{ github.sha }}
restore-keys: |
phpstan-${{ matrix.php }}-${{ matrix.laravel }}-
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: mbstring, pdo, pdo_sqlite, intl, gd, exif, iconv, imagick
tools: composer:v2
coverage: none
- name: Install dependencies
run: |
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" "pestphp/pest:${{ matrix.pest }}" "pestphp/pest-plugin-laravel:${{ matrix.pest-plugin-laravel }}" --no-interaction --no-update
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction
- name: Run PHPStan
run: composer test:types
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.4
extensions: mbstring, pdo, pdo_sqlite, intl
tools: composer:v2
coverage: none
- name: Install dependencies
run: composer install --no-interaction
- name: Run Laravel Pint
run: composer test:lint