|
1 | | -name: PHPUnit tests |
| 1 | +name: "Run unit tests" |
2 | 2 |
|
3 | 3 | on: |
4 | | - push: |
5 | | - branches: [ master ] |
6 | | - pull_request: |
7 | | - branches: [ master ] |
| 4 | + - push |
| 5 | + - pull_request |
| 6 | + - workflow_dispatch |
8 | 7 |
|
9 | | -jobs: |
10 | | - php-version: |
| 8 | +env: |
| 9 | + COMPOSER_MEMORY_LIMIT: -1 |
11 | 10 |
|
| 11 | +jobs: |
| 12 | + test: |
| 13 | + name: "Build" |
12 | 14 | runs-on: ubuntu-latest |
13 | 15 |
|
14 | 16 | strategy: |
15 | | - fail-fast: false |
| 17 | + max-parallel: 12 |
16 | 18 | matrix: |
17 | | - php-version: |
18 | | - - "7.1" |
19 | | - - "7.2" |
20 | | - - "7.3" |
21 | | - - "7.4" |
22 | | - - "8.0" |
23 | | - - "8.1" |
24 | | - - "8.2" |
25 | | - - "8.3" |
26 | | - - "8.4" |
| 19 | + php: ['7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4'] |
| 20 | + package-release: [dist] |
27 | 21 |
|
28 | 22 | steps: |
29 | | - |
30 | | - - uses: actions/checkout@v4 |
31 | | - |
32 | | - - name: Install PHP |
33 | | - uses: "shivammathur/setup-php@v2" |
34 | | - with: |
35 | | - php-version: "${{ matrix.php-version }}" |
36 | | - coverage: "none" |
37 | | - ini-values: "zend.assertions=1" |
38 | | - |
39 | | - - name: Install Composer dependencies |
40 | | - run: composer install --no-progress --ansi |
41 | | - |
42 | | - - name: Run tests ${{ matrix.php-version }} |
43 | | - run: SYMFONY_PHPUNIT_REMOVE_RETURN_TYPEHINT=1 bin/simple-phpunit --color=always |
| 23 | + - name: Checkout repository |
| 24 | + uses: actions/checkout@v4 |
| 25 | + |
| 26 | + - name: Setup PHP ${{ matrix.php }} |
| 27 | + uses: shivammathur/setup-php@v2 |
| 28 | + with: |
| 29 | + php-version: ${{ matrix.php }} |
| 30 | + extensions: exif,json,mbstring,dom |
| 31 | + |
| 32 | + - name: Install composer dependencies |
| 33 | + uses: ramsey/composer-install@v3 |
| 34 | + with: |
| 35 | + dependency-versions: ${{ matrix.package-release }} |
| 36 | + |
| 37 | + - name: Run unit tests |
| 38 | + run: ./vendor/bin/phpunit |
0 commit comments