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); + }); +});