diff --git a/tests/e2e/campaignAgendaFeed.e2e.spec.ts b/tests/e2e/campaignAgendaFeed.e2e.spec.ts index d7be936d..e7697c24 100644 --- a/tests/e2e/campaignAgendaFeed.e2e.spec.ts +++ b/tests/e2e/campaignAgendaFeed.e2e.spec.ts @@ -2,10 +2,22 @@ import { formatBahiaCivilDate, parseBahiaDateTimeInput } from '../../src/lib/cam import { hookFilledCreateData } from '../../src/utilities/hookFilledData.js' import { campaignPageChrome, expect, test } from './fixtures/campaignE2EFixtures.js' +/** + * The full generate → fetch flow needs the app served from a local origin: + * `getCampaignInviteBaseURL` rejects non-public DNS in NODE_ENV=production + * (fail-closed — the feed URL must be canonical), and CI/`pnpm push` boot the + * production build (`E2E_PROD=1`) with `NEXT_PUBLIC_SITE_URL=http://localhost:3000`. + * The CI covers the unlocked dialog via the C93 component unit and the + * filterless feed content via the C93 int tests; the e2e here pins the real + * end-to-end flow on the dev server. + */ +const isProdMode = process.env.E2E_PROD === '1' || process.env.CI === '1' + test.describe('Agenda — link de import (C98)', () => { test.setTimeout(90_000) test('gera o link sem filtros pelo header e o feed responde iCal', async ({ campaign, page }) => { + test.skip(isProdMode, 'fluxo completo exige origem local (dev server)') const { fixtures } = campaign const coordinator = await fixtures.createCampaignUser('coordinator') const municipality = await fixtures.claimMunicipality() @@ -58,6 +70,7 @@ test.describe('Agenda — link de import (C98)', () => { }) test('gera o link sem filtros pelo FAB mobile', async ({ campaign, page }) => { + test.skip(isProdMode, 'fluxo completo exige origem local (dev server)') const { fixtures } = campaign const coordinator = await fixtures.createCampaignUser('coordinator') const municipality = await fixtures.claimMunicipality()