From 27a445b9c8f5ef6061cb49ee91d4382aaebdcb30 Mon Sep 17 00:00:00 2001 From: Laravel Shift Date: Tue, 12 Mar 2024 17:17:13 -0400 Subject: [PATCH] Laravel 11.x Compatibility (#23) * Bump dependencies for Laravel 11 * Update GitHub Actions for Laravel 11 * Fix styling * wip --------- Co-authored-by: laravel-shift Co-authored-by: Ryan Chandler --- .github/workflows/run-tests.yml | 16 ++++++++++++---- .gitignore | 2 +- composer.json | 6 +++--- phpunit.xml.dist | 10 ++++++---- tests/TurnstileBladeDirectiveTest.php | 1 + tests/TurnstileScriptBladeDirectiveTest.php | 1 + 6 files changed, 24 insertions(+), 12 deletions(-) diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 77de178..525e6ea 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -2,23 +2,31 @@ name: run-tests on: push: - branches: [main] + branches: + - main pull_request: - branches: [main] + branches: + - main jobs: test: runs-on: ${{ matrix.os }} + strategy: fail-fast: true matrix: os: [ubuntu-latest, windows-latest] - php: [8.1] - laravel: [10.*] + php: [8.1, '8.2'] + laravel: ['10.*', '11.*'] stability: [prefer-lowest, prefer-stable] include: - laravel: 10.* testbench: 8.* + - laravel: 11.* + testbench: 9.* + exclude: + - laravel: 11.* + php: 8.1 name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }} diff --git a/.gitignore b/.gitignore index 83c9b9f..a7f372d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ .idea -.phpunit.result.cache +.phpunit.cache build composer.lock coverage diff --git a/composer.json b/composer.json index 1ee5fc2..73b61eb 100644 --- a/composer.json +++ b/composer.json @@ -18,13 +18,13 @@ "require": { "php": "^8.1", "spatie/laravel-package-tools": "^1.13.0", - "illuminate/contracts": "^10.0" + "illuminate/contracts": "^10.0|^11.0" }, "require-dev": { "laravel/pint": "^1.0", - "nunomaduro/collision": "^7.0", + "nunomaduro/collision": "^7.0|^8.0", "nunomaduro/larastan": "^2.0.1", - "orchestra/testbench": "^8.1", + "orchestra/testbench": "^8.1|^9.0", "pestphp/pest": "^2.0", "pestphp/pest-plugin-laravel": "^2.0", "phpstan/extension-installer": "^1.1", diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 48c1802..6cbc6a0 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,14 +1,11 @@ - + tests - - ./src - @@ -18,4 +15,9 @@ + + + ./src + + diff --git a/tests/TurnstileBladeDirectiveTest.php b/tests/TurnstileBladeDirectiveTest.php index 4b79e25..921d82b 100644 --- a/tests/TurnstileBladeDirectiveTest.php +++ b/tests/TurnstileBladeDirectiveTest.php @@ -1,6 +1,7 @@