Skip to content

Workflow update #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 9 additions & 59 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,108 +1,58 @@
name: test
name: Test

on: push
on:
push:
workflow_dispatch:

jobs:
phpcs:

runs-on: ubuntu-latest



steps:
- uses: actions/checkout@v2



- uses: shivammathur/setup-php@v2
with:
php-version: '8.1'



php-version: "8.2"
- run: composer install --no-interaction --prefer-dist



- run: vendor/bin/phpcs

phpstan:

runs-on: ubuntu-latest



steps:
- uses: actions/checkout@v2



- uses: shivammathur/setup-php@v2
with:
php-version: '8.1'



php-version: "8.2"
- run: composer install --no-interaction --prefer-dist



- run: vendor/bin/phpstan analyse

phpunit:
strategy:
matrix:
php: [8.2, 8.1]
laravel: ['9.*', '10.*', '11.*']
php: [8.3, 8.2]
laravel: ["10.*", "11.*"]
os: [ubuntu-latest]
include:
- laravel: 10.*
testbench: ^8.0
- laravel: 9.*
testbench: ^7.0
- laravel: 11.*
testbench: ^9.0
exclude:
- laravel: 11.*
php: 8.1

runs-on: ${{ matrix.os }}

name: phpunit (P${{ matrix.php }} - L${{ matrix.laravel }})

env:
DB_HOST: 127.0.0.1



steps:
- uses: actions/checkout@v2



- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}



- uses: shogo82148/actions-setup-mysql@v1
with:
mysql-version: '8.0'
mysql-version: "8.0"
user: loadfile
password: loadfile-testing
my-cnf: local_infile=1



- run: mysql -uroot -h127.0.0.1 -e 'create database loadfile'



- run: |
composer require "laravel/framework:${{ matrix.laravel }}" "orchestra/testbench:${{ matrix.testbench }}" --no-interaction --no-update
composer update --no-interaction --prefer-dist



- run: vendor/bin/phpunit
11 changes: 5 additions & 6 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,14 @@
}
},
"require": {
"php": "^8.1",
"illuminate/database": "^9.0|^10.0|^11.0"
"php": "^8.2",
"illuminate/database": "^10.0|^11.0"
},
"require-dev": {
"phpunit/phpunit": "^9|^10.5",
"orchestra/testbench": "^7.0|^8.0|^9.0",
"phpunit/phpunit": "^10.5",
"orchestra/testbench": "^8.0|^9.0",
"squizlabs/php_codesniffer": "^3.6",
"vimeo/psalm": "^4.7|^5.22",
"nunomaduro/larastan": "^2.0"
"larastan/larastan": "^2.0|^3.0"
},
"scripts": {
"test-unit": "php ./vendor/bin/phpunit tests/Unit",
Expand Down
Loading