From 2df346cf033395df8527a02cb9bf5185a6fc247d Mon Sep 17 00:00:00 2001 From: Jannis Braun <151788261+TheZwiss@users.noreply.github.com> Date: Sun, 3 May 2026 23:34:57 +0200 Subject: [PATCH] test(federation-identity): scaffold + harness boot smoke --- .../test/federation-identity-deletion.test.ts | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 packages/server/test/federation-identity-deletion.test.ts diff --git a/packages/server/test/federation-identity-deletion.test.ts b/packages/server/test/federation-identity-deletion.test.ts new file mode 100644 index 00000000..90284367 --- /dev/null +++ b/packages/server/test/federation-identity-deletion.test.ts @@ -0,0 +1,23 @@ +import { describe, it, expect, beforeAll, afterAll } from 'vitest'; +import { bootTwoInstances, type TwoInstanceHarness } from './helpers/twoInstanceHarness.js'; +import { peerInstances } from './helpers/seedPeer.js'; + +let harness: TwoInstanceHarness; +let sharedHmacSecret: string; + +beforeAll(async () => { + harness = await bootTwoInstances(); + sharedHmacSecret = await peerInstances(harness.home, harness.remote); +}, 60_000); + +afterAll(async () => { + if (harness) await harness.cleanup(); +}); + +describe('Federation identity deletion — server suite', () => { + it('boots the harness and peers the two instances', async () => { + expect(harness.home.origin).toMatch(/^http:\/\/127\.0\.0\.1:\d+$/); + expect(harness.remote.origin).toMatch(/^http:\/\/127\.0\.0\.1:\d+$/); + expect(sharedHmacSecret).toHaveLength(64); + }); +});