From 24f04b24b6c91eefcb6403e2976d89399c0a17a9 Mon Sep 17 00:00:00 2001 From: Andreas Schantl Date: Tue, 4 Mar 2025 10:55:03 +0100 Subject: [PATCH] Laravel 12 support (#42) Co-authored-by: Duncan McClean --- .github/workflows/run-tests.yml | 16 +++++++++------- .gitignore | 2 +- composer.json | 10 +++++----- tests/__fixtures__/.gitignore | 1 + 4 files changed, 16 insertions(+), 13 deletions(-) create mode 100644 tests/__fixtures__/.gitignore diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 2073b55..3b12a04 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -23,12 +23,14 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest] - php: [8.2, 8.3] - laravel: [10.*, 11.*] - statamic: [5.*] - dependency-version: [prefer-stable] + php: [8.2, 8.3, 8.4] + laravel: [10.*, 11.*, 12.*] + stability: [prefer-lowest, prefer-stable] + exclude: + - php: 8.4 + laravel: 10.* - name: P${{ matrix.php }} - L${{ matrix.laravel }} - S${{ matrix.statamic }} - ${{ matrix.dependency-version }} - ${{ matrix.os }} + name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }} steps: - name: Checkout code @@ -48,8 +50,8 @@ jobs: - name: Install dependencies run: | - composer require "statamic/cms:${{ matrix.statamic }}" "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update - composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction + composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update + composer update --${{ matrix.stability }} --prefer-dist --no-interaction - name: Execute tests run: vendor/bin/phpunit diff --git a/.gitignore b/.gitignore index 4ea6620..05cdcab 100644 --- a/.gitignore +++ b/.gitignore @@ -3,4 +3,4 @@ .DS_Store composer.lock .php-cs-fixer.cache -build/report.junit.xml +.phpunit.cache diff --git a/composer.json b/composer.json index 8abbae8..302f3bb 100644 --- a/composer.json +++ b/composer.json @@ -23,17 +23,17 @@ } ], "require": { - "php": "^8.1", + "php": "^8.2", "meilisearch/meilisearch-php": "^1.0", "guzzlehttp/guzzle": "^7.3", "http-interop/http-factory-guzzle": "^1.0", - "illuminate/support": "^10.0 || ^11.0", + "illuminate/support": "^10.0 || ^11.0 || ^12.0", "statamic/cms": "^5.0" }, "require-dev": { - "laravel/pint": "^1.17", - "orchestra/testbench": "^8.14 || ^9.0", - "phpunit/phpunit": "^10.0" + "laravel/pint": "^1.21", + "orchestra/testbench": "^8.14 || ^9.0 || ^10.0", + "phpunit/phpunit": "^10.0 || ^11.5.10" }, "autoload": { "psr-4": { diff --git a/tests/__fixtures__/.gitignore b/tests/__fixtures__/.gitignore new file mode 100644 index 0000000..b722e9e --- /dev/null +++ b/tests/__fixtures__/.gitignore @@ -0,0 +1 @@ +!.gitignore \ No newline at end of file