diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index bea62b49..cc8a276b 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -14,15 +14,19 @@ jobs: matrix: os: [ubuntu-latest, windows-latest] php: [8.2, 8.1, 8.0] - laravel: [9.*, 10.*, 11.*] + laravel: [9.*, 10.*, 11.*, 12.*] stability: [prefer-lowest, prefer-stable] exclude: - php: 8.0 laravel: 10.* - php: 8.0 laravel: 11.* + - php: 8.0 + laravel: 12.* - php: 8.1 laravel: 11.* + - php: 8.1 + laravel: 12.* - php: 8.2 laravel: 9.* include: @@ -38,6 +42,10 @@ jobs: testbench: 9.* pest: 2.* collision: 8.* + - laravel: 12.* + testbench: 10.* + pest: 3.* + collision: 8.* name: P${{ matrix.php }} - L${{ matrix.laravel }} - ${{ matrix.stability }} - ${{ matrix.os }} diff --git a/composer.json b/composer.json index 0764a0c4..577dd9c7 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ ], "require": { "php": "^8.0", - "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0", + "illuminate/contracts": "^8.0|^9.0|^10.0|^11.0|^12.0", "opcodesio/mail-parser": "^0.1.6" }, "require-dev": { @@ -28,9 +28,9 @@ "itsgoingd/clockwork": "^5.1", "laravel/pint": "^1.0", "nunomaduro/collision": "^7.0|^8.0", - "orchestra/testbench": "^7.6|^8.0|^9.0", - "pestphp/pest": "^2.0", - "pestphp/pest-plugin-laravel": "^2.0", + "orchestra/testbench": "^7.6|^8.0|^9.0|^10.0", + "pestphp/pest": "^2.0|^3.7", + "pestphp/pest-plugin-laravel": "^2.0|^3.1", "spatie/test-time": "^1.3" }, "suggest": { diff --git a/tests/Pest.php b/tests/Pest.php index c21ea6fc..a89d8a9b 100644 --- a/tests/Pest.php +++ b/tests/Pest.php @@ -39,6 +39,8 @@ function generateLogFile(?string $fileName = null, ?string $content = null, bool $fileName = \Illuminate\Support\Str::random().'.log'; } + $fileName = str_replace('/', DIRECTORY_SEPARATOR, $fileName); + $path = storage_path('logs'.DIRECTORY_SEPARATOR.$fileName); $folder = dirname($path); diff --git a/tests/Unit/FilePathsTest.php b/tests/Unit/FilePathsTest.php index 52dd18fe..a22fa367 100644 --- a/tests/Unit/FilePathsTest.php +++ b/tests/Unit/FilePathsTest.php @@ -120,7 +120,7 @@ expect($files)->toHaveCount(1); $file = $files[0]; expect($file->path)->toBe($originalFile->path) - ->and($file->displayPath)->toBe('TestPath/first.log') + ->and($file->displayPath)->toBe('TestPath'.DIRECTORY_SEPARATOR.'first.log') ->and($file->subFolder)->toBe('TestPath'); }); @@ -136,6 +136,6 @@ expect($files)->toHaveCount(1); $file = $files[0]; expect($file->path)->toBe($originalFile->path) - ->and($file->displayPath)->toBe('TestPath/first.log') + ->and($file->displayPath)->toBe('TestPath'.DIRECTORY_SEPARATOR.'first.log') ->and($file->subFolder)->toBe('TestPath'); });