Save workspace changes

This commit is contained in:
2026-04-18 17:02:56 +02:00
parent f02ea9a711
commit 87d60af5a9
4220 changed files with 1388603 additions and 1554 deletions

View File

@@ -0,0 +1,45 @@
<?php
declare(strict_types=1);
use App\Models\Artwork;
use App\Models\User;
it('renders the canonical profile gallery page', function () {
$user = User::factory()->create([
'username' => 'gregor',
]);
Artwork::factory()->create([
'user_id' => $user->id,
'title' => 'Gallery Artwork',
'is_public' => true,
'is_approved' => true,
'published_at' => now()->subDay(),
]);
$this->get('/@gregor/gallery')
->assertOk()
->assertSee('http://skinbase26.test/@gregor/gallery', false)
->assertSee('Profile\\/ProfileGallery', false);
});
it('redirects the legacy gallery route to the canonical profile gallery', function () {
$user = User::factory()->create([
'username' => 'gregor',
]);
$this->get('/gallery/' . $user->id . '/Gregor%20Klev%C5%BEe')
->assertRedirect('/@gregor/gallery')
->assertStatus(301);
});
it('redirects mixed-case profile gallery usernames to the lowercase canonical route', function () {
User::factory()->create([
'username' => 'gregor',
]);
$this->get('/@Gregor/gallery')
->assertRedirect('/@gregor/gallery')
->assertStatus(301);
});