From 0e5566bd3e8dc1bf8cdf409dcbd1b66f01199dcf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Turan=20Karatu=C4=9F?= Date: Sun, 19 Feb 2023 17:54:46 +0300 Subject: [PATCH] Add laravel 10 && php 8.2 support --- composer.json | 4 ++-- src/Traits/HasScopeAssertion.php | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/composer.json b/composer.json index 49d1f30..989bf91 100644 --- a/composer.json +++ b/composer.json @@ -18,8 +18,8 @@ } ], "require": { - "php": "^8.0|^8.1", - "illuminate/contracts": "^8.0|^9.0" + "php": "^8.0|^8.1|^8.2", + "illuminate/contracts": "^8.0|^9.0|^10.0" }, "autoload": { "psr-4": { diff --git a/src/Traits/HasScopeAssertion.php b/src/Traits/HasScopeAssertion.php index cf81a4d..5b608aa 100644 --- a/src/Traits/HasScopeAssertion.php +++ b/src/Traits/HasScopeAssertion.php @@ -20,7 +20,7 @@ public function assertScopeCalled(string $scope, string $model, ?int $times = nu return true; }); - $this->assertTrue(in_array($scope, $triggeredScopes[$model])); + $this->assertContains($scope, $triggeredScopes[$model]); if (!is_null($times)) { $this->assertCount( @@ -29,4 +29,4 @@ public function assertScopeCalled(string $scope, string $model, ?int $times = nu ); } } -} \ No newline at end of file +}