Skip to content
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions resources/js/components/app-header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import AppLogoIcon from './app-logo-icon';
const mainNavItems: NavItem[] = [
{
title: 'Dashboard',
url: '/dashboard',
url: route('dashboard'),
icon: LayoutGrid,
},
];
Expand Down Expand Up @@ -94,7 +94,7 @@ export function AppHeader({ breadcrumbs = [] }: AppHeaderProps) {
</Sheet>
</div>

<Link href="/dashboard" prefetch className="flex items-center space-x-2">
<Link href={route('dashboard')} prefetch className="flex items-center space-x-2">
<AppLogo />
</Link>

Expand Down
4 changes: 2 additions & 2 deletions resources/js/components/app-sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import AppLogo from './app-logo';
const mainNavItems: NavItem[] = [
{
title: 'Dashboard',
url: '/dashboard',
url: route('dashboard'),
icon: LayoutGrid,
},
];
Expand All @@ -35,7 +35,7 @@ export function AppSidebar() {
<SidebarMenu>
<SidebarMenuItem>
<SidebarMenuButton size="lg" asChild>
<Link href="/dashboard" prefetch>
<Link href={route('dashboard')} prefetch>
<AppLogo />
</Link>
</SidebarMenuButton>
Expand Down
6 changes: 3 additions & 3 deletions resources/js/layouts/settings/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@ import { Link } from '@inertiajs/react';
const sidebarNavItems: NavItem[] = [
{
title: 'Profile',
url: '/settings/profile',
url: route('profile.edit'),
icon: null,
},
{
title: 'Password',
url: '/settings/password',
url: route('password.edit'),
icon: null,
},
{
title: 'Appearance',
url: '/settings/appearance',
url: route('appearance'),
icon: null,
},
];
Expand Down
2 changes: 1 addition & 1 deletion resources/js/pages/dashboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { Head } from '@inertiajs/react';
const breadcrumbs: BreadcrumbItem[] = [
{
title: 'Dashboard',
href: '/dashboard',
href: route('dashboard'),
},
];

Expand Down
3 changes: 2 additions & 1 deletion routes/auth.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@
Route::get('confirm-password', [ConfirmablePasswordController::class, 'show'])
->name('password.confirm');

Route::post('confirm-password', [ConfirmablePasswordController::class, 'store']);
Route::post('confirm-password', [ConfirmablePasswordController::class, 'store'])
->name('password.confirmation');

Route::post('logout', [AuthenticatedSessionController::class, 'destroy'])
->name('logout');
Expand Down
2 changes: 1 addition & 1 deletion tests/Feature/Auth/EmailVerificationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public function test_email_verification_screen_can_be_rendered()
{
$user = User::factory()->unverified()->create();

$response = $this->actingAs($user)->get('/verify-email');
$response = $this->actingAs($user)->get(round('verification.notice'));

$response->assertStatus(200);
}
Expand Down
6 changes: 3 additions & 3 deletions tests/Feature/Auth/PasswordConfirmationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public function test_confirm_password_screen_can_be_rendered()
{
$user = User::factory()->create();

$response = $this->actingAs($user)->get('/confirm-password');
$response = $this->actingAs($user)->get(route('password.confirm'));

$response->assertStatus(200);
}
Expand All @@ -23,7 +23,7 @@ public function test_password_can_be_confirmed()
{
$user = User::factory()->create();

$response = $this->actingAs($user)->post('/confirm-password', [
$response = $this->actingAs($user)->post(route('password.confirmation'), [
'password' => 'password',
]);

Expand All @@ -35,7 +35,7 @@ public function test_password_is_not_confirmed_with_invalid_password()
{
$user = User::factory()->create();

$response = $this->actingAs($user)->post('/confirm-password', [
$response = $this->actingAs($user)->post(route('password.confirmation'), [
'password' => 'wrong-password',
]);

Expand Down
4 changes: 2 additions & 2 deletions tests/Feature/DashboardTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ class DashboardTest extends TestCase

public function test_guests_are_redirected_to_the_login_page()
{
$this->get('/dashboard')->assertRedirect('/login');
$this->get(route('dashboard'))->assertRedirect('/login');
}

public function test_authenticated_users_can_visit_the_dashboard()
{
$this->actingAs($user = User::factory()->create());

$this->get('/dashboard')->assertOk();
$this->get(route('dashboard'))->assertOk();
}
}
Loading