diff --git a/tests/Feature/AdminPlatformOrderIndexPageJumpNoteShouldRenderCompleteBackNavigationComponentTest.php b/tests/Feature/AdminPlatformOrderIndexPageJumpNoteShouldRenderCompleteBackNavigationComponentTest.php new file mode 100644 index 0000000..750cdc3 --- /dev/null +++ b/tests/Feature/AdminPlatformOrderIndexPageJumpNoteShouldRenderCompleteBackNavigationComponentTest.php @@ -0,0 +1,38 @@ +seed(); + + $this->post('/admin/login', [ + 'email' => 'platform.admin@demo.local', + 'password' => 'Platform@123456', + ])->assertRedirect('/admin'); + } + + public function test_platform_orders_page_jump_note_should_render_complete_back_navigation_component(): void + { + $this->loginAsPlatformAdmin(); + + $res = $this->get('/admin/platform-orders'); + $res->assertOk(); + + $html = (string) $res->getContent(); + $this->assertStringContainsString('data-role="po-page-jump-note"', $html); + $this->assertStringContainsString('仅用于页内快速跳转,不会改变当前筛选状态;', $html); + $this->assertStringContainsString('data-role="po-page-jump-back-to-top"', $html); + $this->assertStringContainsString('data-role="po-page-jump-back-to-quick-filters"', $html); + $this->assertStringContainsString('data-role="po-page-jump-back-to-summary"', $html); + $this->assertStringContainsString('data-role="po-page-jump-back-to-tools"', $html); + $this->assertStringContainsString('data-role="po-page-jump-back-to-list"', $html); + } +}