|
1 | 1 | name: run-tests |
2 | 2 |
|
3 | 3 | on: |
4 | | - push: |
5 | | - pull_request: |
6 | | - schedule: |
7 | | - - cron: '0 0 * * *' |
| 4 | + push: |
| 5 | + pull_request: |
| 6 | + schedule: |
| 7 | + - cron: '0 0 * * *' |
8 | 8 |
|
9 | 9 | jobs: |
10 | | - run-tests: |
11 | | - runs-on: ubuntu-latest |
12 | | - strategy: |
13 | | - fail-fast: false |
14 | | - matrix: |
15 | | - php: [7.2, 7.3, 7.4] |
16 | | - dependency-version: [prefer-lowest, prefer-stable] |
17 | | - include: |
18 | | - - testbench: 5.* |
19 | | - |
20 | | - name: P${{ matrix.php }} - ${{ matrix.dependency-version }} |
21 | | - |
22 | | - steps: |
23 | | - - name: Update apt |
24 | | - run: sudo apt-get update --fix-missing |
25 | | - |
26 | | - - name: Checkout code |
27 | | - uses: actions/checkout@v1 |
28 | | - |
29 | | - - name: Cache dependencies |
30 | | - uses: actions/cache@v1 |
31 | | - with: |
32 | | - path: ~/.composer/cache/files |
33 | | - key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }} |
34 | | - |
35 | | - - name: Setup PHP |
36 | | - uses: shivammathur/setup-php@v2 |
37 | | - with: |
38 | | - php-version: ${{ matrix.php }} |
39 | | - extensions: json |
40 | | - coverage: pocv |
41 | | - |
42 | | - - name: Install dependencies |
43 | | - run: composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest |
44 | | - - name: Execute tests |
45 | | - run: vendor/bin/phpunit |
| 10 | + test: |
| 11 | + runs-on: ${{ matrix.os }} |
| 12 | + strategy: |
| 13 | + matrix: |
| 14 | + php: [ 7.4, 7.3, 7.2 ] |
| 15 | + dependency-version: [ prefer-lowest, prefer-stable ] |
| 16 | + os: [ ubuntu-latest, windows-latest ] |
| 17 | + |
| 18 | + name: P${{ matrix.php }} - ${{ matrix.dependency-version }} - ${{ matrix.os }} |
| 19 | + |
| 20 | + steps: |
| 21 | + - name: Checkout code |
| 22 | + uses: actions/checkout@v2 |
| 23 | + |
| 24 | + - name: Cache dependencies |
| 25 | + uses: actions/cache@v1 |
| 26 | + with: |
| 27 | + path: ~/.composer/cache/files |
| 28 | + key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }} |
| 29 | + |
| 30 | + - name: Setup PHP |
| 31 | + uses: shivammathur/setup-php@v2 |
| 32 | + with: |
| 33 | + php-version: ${{ matrix.php }} |
| 34 | + extensions: json |
| 35 | + coverage: pocv |
| 36 | + |
| 37 | + - name: Install dependencies |
| 38 | + run: composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest |
| 39 | + |
| 40 | + - name: Execute tests |
| 41 | + run: vendor/bin/phpunit --teamcity |
0 commit comments