livewire: Volt entfernt — Komponenten als Livewire-4-Single-File-Components, Route::livewire(), Livewire::test(); livewire/volt deinstalliert
Some checks are pending
linter / quality (push) Waiting to run
tests / ci (push) Waiting to run

- 83 Komponenten: Livewire\Volt\Component → Livewire\Component
- 73 Routen (admin, auth, customer): Volt::route() → Route::livewire()
- 88 Testdateien: Volt::test/actingAs → Livewire::test/actingAs
- VoltServiceProvider gelöscht; composer remove livewire/volt
- config/livewire.php auf v4-Schlüssel (component_layout, component_placeholder,
  component_locations, make_command: SFC ohne ⚡). Der alte Schlüssel layout war
  wirkungslos; alle gerouteten Komponenten setzen ihr Layout selbst.
- CLAUDE.md, AGENTS.md, boost.json, .cursorrules, Skill volt-development
- Roadmap: erledigt; Larastan erfasst SFCs weiterhin nicht (Blade-Dateien)

Suite 2.325 grün, einer übersprungen; Larastan und Pint ohne Meldung;
route:cache und view:cache laufen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Kevin Adametz 2026-10-06 13:59:36 +00:00
parent 79bb6cf1d0
commit 31da9ea8b6
186 changed files with 889 additions and 1075 deletions

View file

@ -10,7 +10,7 @@ use Database\Seeders\RolesAndPermissionsSeeder;
use Illuminate\Http\UploadedFile;
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Storage;
use Livewire\Volt\Volt as LivewireVolt;
use Livewire\Livewire;
use Tests\TestCase;
test('customer company switcher stores only accessible company context', function () {
@ -26,14 +26,14 @@ test('customer company switcher stores only accessible company context', functio
$this->actingAs($customer);
LivewireVolt::test('customer.company-switcher')
Livewire::test('customer.company-switcher')
->assertSee('Alpha GmbH')
->assertDontSee('Fremde GmbH')
->set('activeCompany', (string) $company->id);
expect(session(CustomerCompanyContext::SessionKey))->toBe($company->id);
LivewireVolt::test('customer.company-switcher')
Livewire::test('customer.company-switcher')
->set('activeCompany', (string) $inaccessibleCompany->id);
expect(session(CustomerCompanyContext::SessionKey))->toBe($company->id);
@ -50,7 +50,7 @@ test('customer company switcher links to selected company detail', function () {
$this->actingAs($customer)
->withSession([CustomerCompanyContext::SessionKey => $company->id]);
LivewireVolt::test('customer.company-switcher')
Livewire::test('customer.company-switcher')
->assertSee('Alpha GmbH')
->assertSee('Firma öffnen')
->assertSee(route('me.press-kits.show', $company->id, absolute: false));
@ -70,7 +70,7 @@ test('customer company switcher limits rendered company options', function () {
$this->actingAs($customer);
LivewireVolt::test('customer.company-switcher')
Livewire::test('customer.company-switcher')
->assertViewHas('companies', fn ($companies) => $companies->count() === 50)
->assertSee('Switcher Firma 55')
->assertSee('Switcher Firma 06')
@ -100,7 +100,7 @@ test('customer press release list is filtered by selected company context', func
$this->actingAs($customer)
->withSession([CustomerCompanyContext::SessionKey => $company->id]);
LivewireVolt::test('customer.press-releases.index')
Livewire::test('customer.press-releases.index')
->assertSee('Alpha GmbH')
->assertDontSee('Alle Firmen')
->assertSee('Alpha Produktmeldung')
@ -126,7 +126,7 @@ test('customer press release list can filter unassigned legacy press releases',
$this->actingAs($customer);
LivewireVolt::test('customer.press-releases.index')
Livewire::test('customer.press-releases.index')
->set('companyFilter', 'unassigned')
->assertSee('Alle Firmen')
->assertSee('Legacy ohne Firma')
@ -155,7 +155,7 @@ test('customer dashboard is filtered by selected company context', function () {
$this->actingAs($customer)
->withSession([CustomerCompanyContext::SessionKey => $company->id]);
LivewireVolt::test('customer.dashboard')
Livewire::test('customer.dashboard')
->assertSee('Übersicht für Alpha GmbH')
->assertSee('Alpha Dashboardmeldung')
->assertDontSee('Beta Dashboardmeldung');
@ -170,7 +170,7 @@ test('customer dashboard shows data quality hints', function () {
$this->actingAs($customer)
->withSession([CustomerCompanyContext::SessionKey => $company->id]);
LivewireVolt::test('customer.dashboard')
Livewire::test('customer.dashboard')
->assertSee('Datenqualität')
->assertSee('Profil unvollständig')
->assertSee('Rechnungsadresse fehlt')
@ -191,7 +191,7 @@ test('customer dashboard links unassigned press release hint to filtered list',
$this->actingAs($customer);
LivewireVolt::test('customer.dashboard')
Livewire::test('customer.dashboard')
->assertSee('Pressemitteilung ohne Firma')
->assertSee('company=unassigned');
});
@ -207,7 +207,7 @@ test('create press release uses selected company context as default', function (
$this->actingAs($customer)
->withSession([CustomerCompanyContext::SessionKey => $otherCompany->id]);
LivewireVolt::test('customer.press-releases.create')
Livewire::test('customer.press-releases.create')
->assertSet('companyId', $otherCompany->id)
->assertSee('Beta GmbH');
});
@ -238,11 +238,11 @@ test('customer can browse own press kits and open a press kit detail', function
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.index')
Livewire::test('customer.press-kits.index')
->assertSee('Alpha Pressemappe')
->assertDontSee('Fremde Pressemappe');
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->assertSee('Alpha Pressemappe')
->assertSee('presse@alpha.test')
->assertSee('Paula Presse')
@ -262,7 +262,7 @@ test('customer cannot open inaccessible press kit detail', function () {
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $otherCompany->id])
Livewire::test('customer.press-kits.show', ['id' => $otherCompany->id])
->assertNotFound();
});
@ -276,7 +276,7 @@ test('responsible customer can manage press kit contacts', function () {
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('startCreateContact')
->set('contactFirstName', 'Mara')
->set('contactLastName', 'Muster')
@ -291,7 +291,7 @@ test('responsible customer can manage press kit contacts', function () {
expect($contact->email)->toBe('mara@example.test');
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('editContact', $contact->id)
->set('contactEmail', 'presse@example.test')
->call('saveContact')
@ -300,7 +300,7 @@ test('responsible customer can manage press kit contacts', function () {
expect($contact->refresh()->email)->toBe('presse@example.test');
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('deleteContact', $contact->id)
->assertSee('Pressekontakt wurde gelöscht.');
@ -317,7 +317,7 @@ test('member customer cannot manage press kit contacts', function () {
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->assertDontSee('Kontakt hinzufügen')
->call('startCreateContact')
->assertForbidden();
@ -338,7 +338,7 @@ test('responsible customer can manage press kit company master data', function (
$logo = UploadedFile::fake()->image('logo.png', 800, 400);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('startEditCompany')
->set('companyName', 'Neue Pressemappe GmbH')
->set('companyEmail', 'neu@example.test')
@ -374,7 +374,7 @@ test('member customer cannot manage press kit company master data', function ()
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->assertDontSee('Stammdaten bearbeiten')
->call('startEditCompany')
->assertForbidden();
@ -394,14 +394,14 @@ test('a deleted press kit contact disappears from the list and cannot be edited
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->assertSee('Kontaktperson')
->call('deleteContact', $contact->id)
->assertDontSee('Kontaktperson');
// Seit Livewire 4.4.7 rendert der Testhelfer ModelNotFoundException wie
// ein echter Request als 404, statt sie zu werfen.
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->assertDontSee('Kontaktperson')
->call('editContact', $contact->id)
->assertNotFound();
@ -427,7 +427,7 @@ test('saving or deleting a press kit contact drops the cached newsroom page', fu
$this->get($url)->assertOk();
expect(Cache::has($cacheKey()))->toBeTrue();
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('startCreateContact')
->set('contactLastName', 'Neu')
->set('contactEmail', 'neu@example.test')
@ -443,7 +443,7 @@ test('saving or deleting a press kit contact drops the cached newsroom page', fu
$this->get($url)->assertOk();
expect(Cache::has($cacheKey()))->toBeTrue();
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('deleteContact', $contact->id);
expect(Cache::has($cacheKey()))->toBeFalse();
@ -470,7 +470,7 @@ test('a failed logo write keeps the previous press kit logo and reports a valida
$this->actingAs($customer);
LivewireVolt::test('customer.press-kits.show', ['id' => $company->id])
Livewire::test('customer.press-kits.show', ['id' => $company->id])
->call('startEditCompany')
->set('companyLogo', UploadedFile::fake()->image('neu.png', 400, 400))
->call('saveCompany')