From e80508fd55fe987581944e9abfd78916ffa7eb0f Mon Sep 17 00:00:00 2001 From: Alessio Date: Wed, 4 May 2022 09:34:20 +0200 Subject: [PATCH 1/3] Add Laravel 9 support --- .github/workflows/ci.yml | 7 ++++++- composer.json | 16 ++++++++-------- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c4b00af..728249f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,12 @@ jobs: fail-fast: true matrix: php: [7.3, 7.4, 8.0, 8.1] - laravel: ["8.*"] + laravel: ["8.*", "9.*"] + exclude: + - php: 7.3 + node: "9.*" + - php: 7.4 + node: "9.*" steps: - uses: actions/checkout@v2 diff --git a/composer.json b/composer.json index 0c89f93..c7f4a6f 100644 --- a/composer.json +++ b/composer.json @@ -17,12 +17,12 @@ } ], "require": { - "php": "^7.3|^8.0", - "illuminate/auth": "^8.0", - "illuminate/console": "^8.0", - "illuminate/encryption": "^8.0", - "illuminate/support": "^8.0", - "illuminate/view": "^8.0", + "php": "^7.3|^8.0.2", + "illuminate/auth": "^8.0|^9.0", + "illuminate/console": "^8.0|^9.0", + "illuminate/encryption": "^8.0|^9.0", + "illuminate/support": "^8.0|^9.0", + "illuminate/view": "^8.0|^9.0", "laravel/socialite": "^5.0", "socialiteproviders/gitlab": "^3.1|^4.0", "socialiteproviders/dropbox": "^4.1" @@ -31,8 +31,8 @@ "fakerphp/faker": "^1.9.1", "mockery/mockery": "^1.4.4", "phpunit/phpunit": "^9.5.10", - "orchestra/testbench": "^6.15", - "friendsofphp/php-cs-fixer": "^2.16" + "orchestra/testbench": "^6.15|^7.4", + "friendsofphp/php-cs-fixer": "^2.16|^3.8" }, "autoload": { "psr-4": { From 906c2d7ed292cec30d61316dd098a7f049984676 Mon Sep 17 00:00:00 2001 From: Alessio Date: Wed, 4 May 2022 10:38:35 +0200 Subject: [PATCH 2/3] wip --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 728249f..5a4f408 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,9 +19,9 @@ jobs: laravel: ["8.*", "9.*"] exclude: - php: 7.3 - node: "9.*" + laravel: "9.*" - php: 7.4 - node: "9.*" + laravel: "9.*" steps: - uses: actions/checkout@v2 From 762409a3f17d2bfdd5fea7ec6dbbdca6c024305a Mon Sep 17 00:00:00 2001 From: Alessio Date: Wed, 4 May 2022 10:49:52 +0200 Subject: [PATCH 3/3] Upgrade CS Fixe config --- .php_cs => .php-cs-fixer.php | 6 +++--- tests/Unit/IdentityLinkTest.php | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) rename .php_cs => .php-cs-fixer.php (86%) diff --git a/.php_cs b/.php-cs-fixer.php similarity index 86% rename from .php_cs rename to .php-cs-fixer.php index cd78072..6d9b8ef 100644 --- a/.php_cs +++ b/.php-cs-fixer.php @@ -9,11 +9,11 @@ 'elseif' => true, 'encoding' => true, 'single_blank_line_at_eof' => true, - 'no_extra_consecutive_blank_lines' => true, + 'no_extra_blank_lines' => true, 'include' => true, 'blank_line_after_namespace' => true, 'not_operator_with_successor_space' => true, - 'lowercase_constants' => true, + 'constant_case' => ['case' => 'lower'], 'lowercase_keywords' => true, 'array_syntax' => ['syntax' => 'short'], 'no_unused_imports' => true @@ -27,7 +27,7 @@ __DIR__.'/tests', ]); -return PhpCsFixer\Config::create() +return (new PhpCsFixer\Config()) ->setFinder($finder) ->setRules($fixers) ->setUsingCache(false); \ No newline at end of file diff --git a/tests/Unit/IdentityLinkTest.php b/tests/Unit/IdentityLinkTest.php index c8f4887..e249c95 100644 --- a/tests/Unit/IdentityLinkTest.php +++ b/tests/Unit/IdentityLinkTest.php @@ -6,7 +6,6 @@ use Oneofftech\Identities\Facades\Identity; use Illuminate\Foundation\Testing\DatabaseMigrations; use InvalidArgumentException; -use Illuminate\Support\Facades\View; use Illuminate\View\Component; use Oneofftech\Identities\View\Components\IdentityLink;