Skip to content

Commit 7ca18c0

Browse files
committed
test(LogChannelTest): Skip test for specific Laravel versions
- Skip the test if Laravel version is between 9.0.0 and 10.0.0 - Ensure compatibility with the current framework version - Enhance test reliability by avoiding incompatible version runs
1 parent d64aeaa commit 7ca18c0

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/Channels/LogChannelTest.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,15 @@
1414
* @see https://github.com/guanguans/laravel-exception-notify
1515
*/
1616

17+
use Composer\Semver\Comparator;
1718
use Guanguans\LaravelExceptionNotify\ExceptionNotifyManager;
19+
use Illuminate\Foundation\Application;
1820

1921
it('can report', function (): void {
2022
expect($this->app->make(ExceptionNotifyManager::class)->driver('log'))
2123
->report('report')
2224
->toBeNull();
23-
})->group(__DIR__, __FILE__);
25+
})->group(__DIR__, __FILE__)->skip(
26+
Comparator::greaterThanOrEqualTo(Application::VERSION, '9.0.0')
27+
&& Comparator::lessThan(Application::VERSION, '10.0.0')
28+
);

0 commit comments

Comments
 (0)