From 4fa65724d209a47f7ce9c9cd8a30d41b9bb6e8e4 Mon Sep 17 00:00:00 2001 From: Francisco Solla Date: Mon, 24 Aug 2026 17:05:11 -0300 Subject: [PATCH] =?UTF-8?q?fix(e2e):=20OPS87=20follow-up=20=E2=80=94=20res?= =?UTF-8?q?taura=20teste=20'the=20omnibox=20narrows=20the=20people=20recor?= =?UTF-8?q?te'=20perdido=20no=20rebase-merge=20do=20PR=20#853?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/e2e/campaignPeople.e2e.spec.ts | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/tests/e2e/campaignPeople.e2e.spec.ts b/tests/e2e/campaignPeople.e2e.spec.ts index 4a026e24..76d020cd 100644 --- a/tests/e2e/campaignPeople.e2e.spec.ts +++ b/tests/e2e/campaignPeople.e2e.spec.ts @@ -24,6 +24,32 @@ test.describe('Pessoas — lista unificada', () => { * * HTTP twin: tests/e2e/campaignPeopleHttp.e2e.spec.ts. */ + test('the omnibox narrows the people recorte', async ({ campaign, page }) => { + const { fixtures } = campaign + const coordinator = await fixtures.createCampaignUser('coordinator', { + name: fixtures.value('Coordenadora Pessoas'), + }) + const municipality = await fixtures.claimMunicipality() + const { contactName } = await fixtures.createStaffLeadership({ + namePrefix: 'Liderança Pessoas', + municipalities: [municipality], + }) + + await campaign.login(page, coordinator.email!, coordinator.password) + + await page.goto('/campanha/pessoas') + await expect(campaignPageChrome(page, 'Pessoas')).toBeVisible() + + // The omnibox search narrows the recorte (canonical URL, chips mounted). + const omnibox = page.getByRole('combobox', { name: 'Filtrar pessoas' }) + await omnibox.fill(contactName.slice(0, 8)) + await omnibox.press('Enter') + await expect(page).toHaveURL(/q=/) + // The filter navigation re-streams the list — let it commit before the row. + await page.waitForFunction(() => document.querySelectorAll('div[id^="S:"]').length === 0) + await expect(page.getByRole('row', { name: new RegExp(contactName) })).toBeVisible() + }) + test('staff sorts by a column header and filters absence via the omnibox (C117)', async ({ campaign, page,