Apply Pint 1.29 formatting
The Laravel 13 upgrade pulled Pint 1.27.1 to 1.29.3, which changed the laravel preset's default rules. composer lint and the CI lint job fail without this, so it is required rather than cosmetic. Formatting only, applied by `vendor/bin/pint`. The rules that fired were fully_qualified_strict_types, ordered_imports, single_blank_line_at_eof, unary_operator_spaces, not_operator_with_successor_space, braces_position, single_line_empty_body, single_line_after_imports and no_extra_blank_lines. Kept separate from the upgrade commit to keep that diff reviewable. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
1ebd51248e
commit
9f929c7a78
@@ -2,4 +2,4 @@
|
||||
|
||||
test('that true is true', function () {
|
||||
expect(true)->toBeTrue();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
<?php
|
||||
|
||||
use App\Services\FileEncryptionService;
|
||||
use Symfony\Component\HttpFoundation\StreamedResponse;
|
||||
|
||||
beforeEach(function () {
|
||||
$this->service = new FileEncryptionService;
|
||||
@@ -119,7 +120,7 @@ test('decrypt file stream returns streamed response', function () {
|
||||
|
||||
$response = $this->service->decryptFileStream($encryptedPath, $key, 'test.txt', 'text/plain');
|
||||
|
||||
expect($response)->toBeInstanceOf(Symfony\Component\HttpFoundation\StreamedResponse::class);
|
||||
expect($response)->toBeInstanceOf(StreamedResponse::class);
|
||||
expect($response->headers->get('Content-Type'))->toBe('text/plain');
|
||||
expect($response->headers->get('Content-Disposition'))->toContain('test.txt');
|
||||
});
|
||||
@@ -219,7 +220,6 @@ test('wrong key on chunked file throws exception', function () {
|
||||
$this->service->decryptFile($encryptedPath, $wrongKey);
|
||||
})->throws(RuntimeException::class, 'Decryption failed');
|
||||
|
||||
|
||||
test('decrypt file stream with file size sets content-length header', function () {
|
||||
$sourcePath = $this->tempDir.'/source.txt';
|
||||
$encryptedPath = $this->tempDir.'/encrypted.enc';
|
||||
|
||||
@@ -4,11 +4,14 @@ use App\Models\Setting;
|
||||
use App\Models\Share;
|
||||
use App\Models\ShareFile;
|
||||
use App\Services\ShareService;
|
||||
use Illuminate\Foundation\Testing\RefreshDatabase;
|
||||
use Illuminate\Http\UploadedFile;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Illuminate\Support\Facades\Storage;
|
||||
use Tests\TestCase;
|
||||
|
||||
pest()->extend(Tests\TestCase::class)
|
||||
->use(Illuminate\Foundation\Testing\RefreshDatabase::class);
|
||||
pest()->extend(TestCase::class)
|
||||
->use(RefreshDatabase::class);
|
||||
|
||||
beforeEach(function () {
|
||||
Storage::fake('shares');
|
||||
@@ -42,7 +45,7 @@ test('create share with password does not store encryption key', function () {
|
||||
|
||||
expect($share->password)->not->toBeNull();
|
||||
expect($share->encryption_key)->toBeNull();
|
||||
expect(\Illuminate\Support\Facades\Hash::check('my-password', $share->password))->toBeTrue();
|
||||
expect(Hash::check('my-password', $share->password))->toBeTrue();
|
||||
});
|
||||
|
||||
test('create share with options sets expiration and max downloads', function () {
|
||||
|
||||
Reference in New Issue
Block a user