-
Notifications
You must be signed in to change notification settings - Fork 30
88 lines (83 loc) · 2.61 KB
/
testing-and-cs.yaml
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
85
86
87
name: Testing and Code Quality
on: [push, pull_request]
jobs:
PHPCS:
name: Code Sniffing
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: 'Composer install'
uses: docker://composer:2.2
with:
args: install
- name: 'Code sniffing'
uses: docker://php:8.1-cli
with:
args: "vendor/bin/php-cs-fixer fix src --dry-run"
PHPUnit-Symfony45:
name: PHPUnit testing
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ["7.2", "7.3", "7.4", "8.0", "8.1"]
composer: ["1.10", "2.0", "2.1", "2.2"]
symfony: ["^4.0", "^5.0"]
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: 'Unit testing'
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: composer:${{ matrix.composer }}
- run: composer require "symfony/finder:${{ matrix.symfony }}" "symfony/filesystem:${{ matrix.symfony }}"
- run: composer install
- run: vendor/bin/phpunit
PHPUnit-Symfony56:
name: PHPUnit testing
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ["8.0", "8.1"]
composer: ["2.0", "2.1", "2.2", "2.3", "2.4", "2.5", "2.6", "2.7"]
symfony: ["^5.4", "^6.0"]
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: 'Unit testing'
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: composer:${{ matrix.composer }}
- run: composer require "symfony/finder:${{ matrix.symfony }}" "symfony/filesystem:${{ matrix.symfony }}"
- run: composer install
- run: vendor/bin/phpunit
PHPUnit-Symfony7:
name: PHPUnit testing
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ["8.2"]
composer: ["2.0", "2.1", "2.2", "2.3", "2.4", "2.5", "2.6", "2.7"]
symfony: ["^7.0"]
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: 'Unit testing'
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: composer:${{ matrix.composer }}
- run: composer require "symfony/finder:${{ matrix.symfony }}" "symfony/filesystem:${{ matrix.symfony }}"
- run: composer install
- run: vendor/bin/phpunit
BuildDone:
name: PHP full build
needs: [PHPCS, PHPUnit-Symfony45, PHPUnit-Symfony56, PHPUnit-Symfony7]
runs-on: ubuntu-latest
steps:
- run: "echo build done"