From 0abeb1a04130b907090351e8787adde5e12d7329 Mon Sep 17 00:00:00 2001 From: rcourtman Date: Fri, 10 Jul 2026 08:50:44 +0100 Subject: [PATCH] Update stale Patrol readiness copy assertions to match shipped strings Commit 20b310201 renamed the Patrol provider-setup action copy ('Check model' -> 'Fix setup', 'Open Provider & Models' -> 'Check Patrol model' with href /settings/pulse-intelligence/patrol) and updated the sibling patrol tests, but missed these four, leaving build-and-test.yml red on main. Point them at the shipped copy. --- .../components/AI/__tests__/FindingsPanel.links.test.tsx | 8 ++++---- .../components/patrol/__tests__/RunHistoryEntry.test.tsx | 6 +++--- .../patrol/__tests__/PatrolIntelligenceHeader.test.ts | 2 +- .../patrol/__tests__/patrolCommercialBoundary.test.ts | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/frontend-modern/src/components/AI/__tests__/FindingsPanel.links.test.tsx b/frontend-modern/src/components/AI/__tests__/FindingsPanel.links.test.tsx index f90e05853d..986639cf21 100644 --- a/frontend-modern/src/components/AI/__tests__/FindingsPanel.links.test.tsx +++ b/frontend-modern/src/components/AI/__tests__/FindingsPanel.links.test.tsx @@ -262,9 +262,9 @@ describe('FindingsPanel resource links', () => { await waitFor(() => expect(mockState.loadPatrolFindings).toHaveBeenCalled()); - expect(screen.getByRole('link', { name: 'Open Provider & Models' })).toHaveAttribute( + expect(screen.getByRole('link', { name: 'Check Patrol model' })).toHaveAttribute( 'href', - '/settings/pulse-intelligence/provider', + '/settings/pulse-intelligence/patrol', ); fireEvent.click( @@ -273,9 +273,9 @@ describe('FindingsPanel resource links', () => { }), ); - expect(screen.getByRole('link', { name: 'Open Provider & Models' })).toHaveAttribute( + expect(screen.getByRole('link', { name: 'Check Patrol model' })).toHaveAttribute( 'href', - '/settings/pulse-intelligence/provider', + '/settings/pulse-intelligence/patrol', ); expect(screen.queryByRole('button', { name: 'Open in Assistant' })).not.toBeInTheDocument(); expect(screen.queryByText('Manage')).not.toBeInTheDocument(); diff --git a/frontend-modern/src/components/patrol/__tests__/RunHistoryEntry.test.tsx b/frontend-modern/src/components/patrol/__tests__/RunHistoryEntry.test.tsx index b318537bfa..c560da39a3 100644 --- a/frontend-modern/src/components/patrol/__tests__/RunHistoryEntry.test.tsx +++ b/frontend-modern/src/components/patrol/__tests__/RunHistoryEntry.test.tsx @@ -238,9 +238,9 @@ describe('RunHistoryEntry', () => { expect(screen.queryByText(/tool_choice/)).toBeNull(); expect(screen.queryByText(/No endpoints found/)).toBeNull(); expect(screen.getByText('error')).toBeInTheDocument(); - expect(screen.getByRole('link', { name: 'Open Provider & Models' })).toHaveAttribute( + expect(screen.getByRole('link', { name: 'Check Patrol model' })).toHaveAttribute( 'href', - '/settings/pulse-intelligence/provider', + '/settings/pulse-intelligence/patrol', ); }); @@ -260,7 +260,7 @@ describe('RunHistoryEntry', () => { /> )); - expect(screen.queryByRole('link', { name: 'Open Provider & Models' })).toBeNull(); + expect(screen.queryByRole('link', { name: 'Check Patrol model' })).toBeNull(); }); it('opens Assistant with structured run history context', () => { diff --git a/frontend-modern/src/features/patrol/__tests__/PatrolIntelligenceHeader.test.ts b/frontend-modern/src/features/patrol/__tests__/PatrolIntelligenceHeader.test.ts index 3ab85cf58a..dbd2f8710f 100644 --- a/frontend-modern/src/features/patrol/__tests__/PatrolIntelligenceHeader.test.ts +++ b/frontend-modern/src/features/patrol/__tests__/PatrolIntelligenceHeader.test.ts @@ -77,7 +77,7 @@ describe('PatrolIntelligenceHeader', () => { expect(headerSource).toContain("state.patrolReadiness()?.status === 'not_ready'"); expect(headerSource).toContain('getPatrolProviderSettingsAction'); expect(headerSource).toContain('providerSetupAction.href'); - expect(headerSource).toContain('Check model'); + expect(headerSource).toContain('Fix setup'); expect(headerSource).toContain('Check Patrol model:'); expect(headerSource).toContain('runButtonDisabled'); expect(headerSource).not.toContain('!state.canTriggerPatrol() ||'); diff --git a/frontend-modern/src/features/patrol/__tests__/patrolCommercialBoundary.test.ts b/frontend-modern/src/features/patrol/__tests__/patrolCommercialBoundary.test.ts index 5af62b5965..5954158c43 100644 --- a/frontend-modern/src/features/patrol/__tests__/patrolCommercialBoundary.test.ts +++ b/frontend-modern/src/features/patrol/__tests__/patrolCommercialBoundary.test.ts @@ -58,7 +58,7 @@ describe('patrol commercial boundary', () => { "state.patrolReadiness()?.status !== 'not_ready'", ); expect(patrolIntelligenceBannersSource).toContain(''); - expect(patrolIntelligenceHeaderSource).toContain('Check model'); + expect(patrolIntelligenceHeaderSource).toContain('Fix setup'); }); it('does not carry the removed patrol configuration panel chrome', () => {