-
Notifications
You must be signed in to change notification settings - Fork 207
53 lines (50 loc) · 1.48 KB
/
tests.yml
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
name: tests
on:
push:
pull_request:
schedule:
- cron: '0 0 * * *'
jobs:
run:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: [8.2]
laravel: [11.0]
name: P${{ matrix.php }} - L${{ matrix.laravel }}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Cache dependencies
uses: actions/cache@v1
with:
path: ~/.composer/cache/files
key: dependencies-laravel-${{ matrix.laravel }}-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
- name: Set up PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pdo, sqlite, pdo_sqlite
coverage: none
- name: Create Laravel app
run: composer create-project laravel/laravel=${{ matrix.laravel }} ../app --prefer-dist
- name: Install dependencies
run: |
cd ../app
composer require livewire/livewire:^3.4
composer config repositories.local '{"type": "path", "url": "../tall"}' --file composer.json
composer require laravel-frontend-presets/tall:@dev
- name: Install preset
run: |
cd ../app
php artisan ui tall --auth
- name: Overwrite configuration
run: |
cd ../app
rm phpunit.xml
cp ../tall/.github/workflows/phpunit.xml.stub ./phpunit.xml
- name: Execute tests
run: |
cd ../app
vendor/bin/phpunit