Skip to content
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
63 changes: 33 additions & 30 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,46 +2,49 @@ name: Tests

on:
push:
branches: [ main, develop ]
branches:
- main
- develop
pull_request:
branches: [ main, develop ]
branches:
- main
- develop

jobs:
build:

runs-on: ubuntu-latest

strategy:
fail-fast: true
matrix:
php: [8.2, 8.3, 8.4]
laravel: [10, 11]
laravel: [10, 11, 12]
phpunit: [10.5, 11]

steps:
- name: Checkout Code
uses: actions/checkout@v3

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip
tools: composer:v2
coverage: none

- name: Set Laravel Version
run: composer require "illuminate/contracts:^${{ matrix.laravel }}" --no-update

- name: Set PHPUnit Version
run: composer require "phpunit/phpunit:^${{ matrix.laravel }}" --no-update

- name: Install dependencies
uses: nick-fields/retry@v2
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --prefer-dist --no-interaction --no-progress

- name: Execute tests
run: vendor/bin/phpunit
- name: Checkout Code
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip
tools: composer:v2
coverage: none

- name: Set Laravel Version
run: composer require "illuminate/contracts:^${{ matrix.laravel }}" --no-update

- name: Set PHPUnit Version
run: composer require "phpunit/phpunit:^${{ matrix.phpunit }}" --no-update

- name: Install dependencies
uses: nick-fields/retry@v3
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --prefer-dist --no-interaction --no-progress

- name: Execute tests
run: vendor/bin/phpunit
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"require": {
"php": "^8.2",
"ext-json": "*",
"illuminate/contracts": "^10.0|^11.0",
"illuminate/support": "^10.0|^11.0",
"illuminate/contracts": "^10.0|^11.0|^12.0",
"illuminate/support": "^10.0|^11.0|^12.0",
"phpunit/phpunit": "^10.5|^11.0"
},
"autoload": {
Expand Down