import assert from "node:assert/strict"; import fs from "node:fs"; import path from "node:path"; import { fileURLToPath } from "node:url"; const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), ".."); const page = fs.readFileSync( path.join(root, "src/features/campaigns/CampaignCollaborationPage.tsx"), "utf8" ); const workspace = fs.readFileSync( path.join(root, "src/features/campaigns/CampaignWorkspace.tsx"), "utf8" ); const sidebar = fs.readFileSync( path.join(root, "src/layout/SectionSidebar.tsx"), "utf8" ); const api = fs.readFileSync(path.join(root, "src/api/campaigns.ts"), "utf8"); assert.match(page, /archetype="collection"/); assert.match(page, /variant="collection"/); assert.match(page, /refreshable/); assert.match(page, /ReferenceMultiSelect/); assert.match(page, /ConfirmDialog/); assert.match(page, /campaigns:discussion:post/); assert.match(page, /campaigns:discussion:moderate/); assert.match(page, /maxLength=\{8000\}/); assert.match(page, /