seedLookupData(); $admin = $this->admin(['name' => 'Helpdesk Settings Admin']); $this->browse(function (Browser $browser) use ($admin): void { $browser->loginAs($admin) ->visitRoute('helpdesk.settings') ->waitFor('@helpdesk-settings-manager') ->assertSee('Support configuration') ->assertSourceMissing("route('helpdesk.tickets.index')") ->assertSourceMissing("route('helpdesk.tickets.create')") ->assertSourceMissing("route('helpdesk.kanban')") ->assertDontSee('+ New Ticket') ->assertDontSee('Kanban'); $this->openSettingsSection($browser, 'statuses', 'Statuses'); $this->openSettingsSection($browser, 'priorities', 'Priorities'); $this->openSettingsSection($browser, 'categories', 'Categories'); $this->openSettingsSection($browser, 'teams', 'Teams'); $this->openSettingsSection($browser, 'projects', 'Projects'); $this->openSettingsSection($browser, 'git', 'Remote URL'); $this->openSettingsSection($browser, 'workflow', 'HTML email body'); }); } private function openSettingsSection(Browser $browser, string $section, string $expectedHeading): Browser { return $browser ->click('@helpdesk-settings-section-' . $section) ->waitForText($expectedHeading, 10); } }