Erfasst den vollständigen Projektstand mit drei Hauptbereichen:
1. Laravel 11 Application-Skelett
- Standard-Setup (app/, bootstrap/, config/, database/, public/, resources/, routes/, storage/, tests/)
- Composer + npm Konfiguration
- Devcontainer für Laravel Sail (PHP/MySQL/Redis)
- GitHub Actions Workflows (lint + tests)
- Tailwind/Vite Build-Pipeline
2. docs/ – Wissensbasis "Marke macht." (Methodik-Verfassung)
Stand nach Pflegerunde 2026-05-28:
- 00_Methodik-Verfassung: Dok. 000 (v2.0.2) bis Dok. 013 (NEU) + Anhänge
- 10_Quellen-Original: Wala, Sharp, Simon (read-only Quellen)
- 20_Markenwissen: 25 abgeleitete MW-Dokumente (Wala_MW-WAL, Sharp_MW-HBG, Simon_MW-SIM)
- 30_Synthese: Markenwissen_I_Synthese_Gesamt + Scorecard-Regeln
- 40_Implementierung: 011b-Erweiterung
- _Steuerung: 00_START_HIER, Serienübersicht, CHANGELOG.md
Letzte methodische Eingriffe:
- Methodik-Update v2.0 (Ownership Autorenschaft/Anwendung, Geltungsbereich Kernthese,
Score-Ebenen DNA-Reifegrad, Preislogik Governance-Scope)
- Dok. 013 NEU: Akquise- & Conversion-Logik (Auffahrten statt Funnel)
- Rebranding brandwork.io → Brand Rules (brand-rules.com)
- Schichtverletzungen behoben, Ordner-Symmetrie hergestellt, Verweise konsolidiert
3. _markemacht.de/ – Web-Frontend Design-Sandbox
- Statische HTML-Entwürfe (Startseite, Methode, Manifest, Denken, Blog)
- Design-System (warm_intellectualism, based_web_design)
- Assets (CSS, JS, Favicon)
Konfiguration:
- .gitignore um .DS_Store und Thumbs.db erweitert
- Lokale Git-Identity gesetzt: Kevin Adametz <kevin.adametz@me.com>
- .env wird ignoriert (nur .env.example versioniert)
Konfliktregel: Bei Spannung zwischen Code und Methodik gilt die Methodik (Dok. 000).
Co-authored-by: Cursor <cursoragent@cursor.com>
72 lines
No EOL
2 KiB
PHP
72 lines
No EOL
2 KiB
PHP
<?php
|
|
|
|
use App\Models\User;
|
|
use Illuminate\Auth\Events\Verified;
|
|
use Illuminate\Support\Facades\Event;
|
|
use Illuminate\Support\Facades\URL;
|
|
use Laravel\Fortify\Features;
|
|
|
|
beforeEach(function () {
|
|
$this->skipUnlessFortifyHas(Features::emailVerification());
|
|
});
|
|
|
|
test('email verification screen can be rendered', function () {
|
|
$user = User::factory()->unverified()->create();
|
|
|
|
$response = $this->actingAs($user)->get(route('verification.notice'));
|
|
|
|
$response->assertOk();
|
|
});
|
|
|
|
test('email can be verified', function () {
|
|
$user = User::factory()->unverified()->create();
|
|
|
|
Event::fake();
|
|
|
|
$verificationUrl = URL::temporarySignedRoute(
|
|
'verification.verify',
|
|
now()->addMinutes(60),
|
|
['id' => $user->id, 'hash' => sha1($user->email)],
|
|
);
|
|
|
|
$response = $this->actingAs($user)->get($verificationUrl);
|
|
|
|
Event::assertDispatched(Verified::class);
|
|
|
|
expect($user->fresh()->hasVerifiedEmail())->toBeTrue();
|
|
$response->assertRedirect(route('dashboard', absolute: false).'?verified=1');
|
|
});
|
|
|
|
test('email is not verified with invalid hash', function () {
|
|
$user = User::factory()->unverified()->create();
|
|
|
|
$verificationUrl = URL::temporarySignedRoute(
|
|
'verification.verify',
|
|
now()->addMinutes(60),
|
|
['id' => $user->id, 'hash' => sha1('wrong-email')],
|
|
);
|
|
|
|
$this->actingAs($user)->get($verificationUrl);
|
|
|
|
expect($user->fresh()->hasVerifiedEmail())->toBeFalse();
|
|
});
|
|
|
|
test('already verified user visiting verification link is redirected without firing event again', function () {
|
|
$user = User::factory()->create([
|
|
'email_verified_at' => now(),
|
|
]);
|
|
|
|
Event::fake();
|
|
|
|
$verificationUrl = URL::temporarySignedRoute(
|
|
'verification.verify',
|
|
now()->addMinutes(60),
|
|
['id' => $user->id, 'hash' => sha1($user->email)],
|
|
);
|
|
|
|
$this->actingAs($user)->get($verificationUrl)
|
|
->assertRedirect(route('dashboard', absolute: false).'?verified=1');
|
|
|
|
expect($user->fresh()->hasVerifiedEmail())->toBeTrue();
|
|
Event::assertNotDispatched(Verified::class);
|
|
}); |