Skip to content

Commit 43e1725

Browse files
committed
add action tests
1 parent b1a1e45 commit 43e1725

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

.github/workflows/tests.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: tests
2+
3+
on:
4+
push:
5+
pull_request:
6+
schedule:
7+
- cron: '0 0 * * *'
8+
9+
jobs:
10+
run-tests:
11+
runs-on: ubuntu-latest
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
php: [7.3, 7.4, 8.0]
16+
laravel: [8.*, 7.*, 6.*]
17+
dependency-version: [prefer-lowest, prefer-stable]
18+
include:
19+
- laravel: 8.*
20+
testbench: 6.*
21+
- laravel: 7.*
22+
testbench: 5.*
23+
- laravel: 6.*
24+
testbench: 4.*
25+
26+
name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.dependency-version }}
27+
28+
steps:
29+
- name: Update apt
30+
run: sudo apt-get update --fix-missing
31+
32+
- name: Checkout code
33+
uses: actions/checkout@v2
34+
35+
- name: Setup PHP
36+
uses: shivammathur/setup-php@v2
37+
with:
38+
php-version: ${{ matrix.php }}
39+
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, exif
40+
coverage: none
41+
42+
- name: Install dependencies
43+
run: |
44+
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
45+
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest
46+
- name: Execute tests
47+
run: vendor/bin/phpunit

0 commit comments

Comments
 (0)