From 92d151df42c6d925a7795ee3ef266568b98cdd24 Mon Sep 17 00:00:00 2001 From: mikemeijer Date: Fri, 3 Feb 2023 15:48:58 +0100 Subject: [PATCH 1/3] Add support for Laravel 10 --- .github/workflows/tests.yml | 6 ++++-- composer.json | 7 ++++--- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 941c977..af60e64 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,11 +11,13 @@ jobs: strategy: matrix: - php: [8.0, 7.4] - laravel: [9.*, 8.*, 7.*, 6.*, 5.8.*] + php: [8.1, 8.0, 7.4] + laravel: [10.*, 9.*, 8.*, 7.*, 6.*, 5.8.*] dependency-version: [prefer-lowest, prefer-stable] os: [ubuntu-latest, windows-latest] include: + - laravel: 10.* + testbench: 8.* - laravel: 9.* testbench: 7.* - laravel: 8.* diff --git a/composer.json b/composer.json index 67bb65d..9024dd9 100644 --- a/composer.json +++ b/composer.json @@ -13,12 +13,12 @@ } ], "require": { - "php": ">=7.1", - "laravel/framework": "^5.2 || ^6.0 || ^7.0 || ^8.0 || ^9.0", + "php": ">=7.1 || ^8.0", + "laravel/framework": "^5.0|^6.0|^7.0|^8.0|^9.0|^10.0", "ext-json": "*" }, "require-dev": { - "orchestra/testbench": "^7.1" + "orchestra/testbench": "^7.1 || ^8.0" }, "autoload": { "psr-4": { @@ -30,6 +30,7 @@ "\"Programic\\\\LaravelConvertCaseMiddleware\\Tests\\": "tests" } }, + "minimum-stability": "dev", "scripts": { "test": [ "vendor/bin/phpunit" From 4b32f9907febb085ea030c4f77e42283b33ad3c7 Mon Sep 17 00:00:00 2001 From: mikemeijer Date: Fri, 3 Feb 2023 15:50:43 +0100 Subject: [PATCH 2/3] Keep pipe notation in composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 9024dd9..d357978 100644 --- a/composer.json +++ b/composer.json @@ -14,7 +14,7 @@ ], "require": { "php": ">=7.1 || ^8.0", - "laravel/framework": "^5.0|^6.0|^7.0|^8.0|^9.0|^10.0", + "laravel/framework": "^5.2 || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0", "ext-json": "*" }, "require-dev": { From 4eb9d4cb27b911fc8da11653603849989b83d352 Mon Sep 17 00:00:00 2001 From: mikemeijer Date: Mon, 13 Feb 2023 11:09:18 +0100 Subject: [PATCH 3/3] Fix workflow --- .github/workflows/tests.yml | 25 ++++++++++++++++++------- composer.json | 5 +++-- tests/TestCase.php | 9 ++------- 3 files changed, 23 insertions(+), 16 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index af60e64..d5a6526 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: - php: [8.1, 8.0, 7.4] + php: [8.2, 8.1, 8.0, 7.4] laravel: [10.*, 9.*, 8.*, 7.*, 6.*, 5.8.*] dependency-version: [prefer-lowest, prefer-stable] os: [ubuntu-latest, windows-latest] @@ -29,14 +29,26 @@ jobs: - laravel: 5.8.* testbench: 3.8.* exclude: + - laravel: 10.* + php: 8.0 + - laravel: 10.* + php: 7.4 - laravel: 9.* php: 7.4 - laravel: 8.* - php: 7.4 + php: 8.2 - laravel: 7.* - php: 8.0 + php: 8.2 + - laravel: 7.* + php: 8.1 + - laravel: 6.* + php: 8.2 - laravel: 6.* - php: 8 + php: 8.1 + - laravel: 5.8.* + php: 8.2 + - laravel: 5.8.* + php: 8.1 - laravel: 5.8.* php: 8.0 @@ -47,11 +59,10 @@ jobs: uses: actions/checkout@v1 - name: Setup PHP - uses: shivammathur/setup-php@v1 + uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php }} - extension-csv: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo - extensions: + extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick, fileinfo coverage: none - name: Install dependencies diff --git a/composer.json b/composer.json index d357978..6098b7e 100644 --- a/composer.json +++ b/composer.json @@ -18,7 +18,8 @@ "ext-json": "*" }, "require-dev": { - "orchestra/testbench": "^7.1 || ^8.0" + "orchestra/testbench": "^7.1 || ^8.0", + "phpunit/phpunit": "^8.5.23 || ^9.5.10" }, "autoload": { "psr-4": { @@ -33,7 +34,7 @@ "minimum-stability": "dev", "scripts": { "test": [ - "vendor/bin/phpunit" + "vendor/bin/phpunit tests" ] } } diff --git a/tests/TestCase.php b/tests/TestCase.php index a7fdc88..c1c4edd 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -2,12 +2,7 @@ namespace Programic\LaravelConvertCaseMiddleware\Tests; -use Orchestra\Testbench\TestCase as Orchestra; - -abstract class TestCase extends Orchestra +abstract class TestCase extends \Orchestra\Testbench\TestCase { - public function setUp(): void - { - parent::setUp(); - } + // }