-
Notifications
You must be signed in to change notification settings - Fork 7
81 lines (64 loc) · 2.04 KB
/
Copy pathtests.yml
File metadata and controls
81 lines (64 loc) · 2.04 KB
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
name: Tests
on:
push:
branches:
- 2.x
- 3.x
paths-ignore:
- '.github/**'
- 'README.md'
pull_request:
branches:
- 2.x
- 3.x
workflow_dispatch:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
php: [8.2,8.3]
laravel: ['12.*', '13.*']
name: OS:${{ matrix.os }} / PHP:${{ matrix.php }} / Laravel:${{ matrix.laravel }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22.x
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick
tools: composer:v2
coverage: none
- name: Install Composer
run: |
composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-progress --ansi --no-update
composer update --no-interaction --no-progress --ansi
- name: Install Node Dependencies
run: |
rm -rf node_modules
rm -f package-lock.json
npm install
npm run build
- name: Copy .env
run: php -r "file_exists('.env') || copy('.env.example', '.env');"
- name: Creating Database
run: php -r "file_exists('database/database.sqlite') || touch('database/database.sqlite');"
- name: Preparing Laravel
run: php artisan key:generate --force && php artisan optimize:clear
- name: Check Route Integrity
run: php artisan route:list
- name: Run Migrations
run: php artisan migrate:fresh --step --force --no-interaction --seed
- name: Pint
run: ./vendor/bin/pint --test
- name: PhpStan
run: ./vendor/bin/phpstan --configuration="phpstan.neon"
- name: Feature Tests
run: ./vendor/bin/pest --ci --parallel