auth-enterprise-pack.test.ts25 lines · main
1import { describe, expect, test } from 'bun:test';
2
3import { ENTERPRISE_LEGAL_TEMPLATES, ENTERPRISE_PACK_VERSION } from './auth-enterprise-pack.js';
4
5describe('enterprise pack templates (S7)', () => {
6 test('pack version is set', () => {
7 expect(ENTERPRISE_PACK_VERSION).toMatch(/^\d{4}-\d{2}-\d{2}$/);
8 });
9
10 test('DPA template has controller/processor', () => {
11 expect(ENTERPRISE_LEGAL_TEMPLATES.dpa.controller.length).toBeGreaterThan(3);
12 expect(ENTERPRISE_LEGAL_TEMPLATES.dpa.processor).toContain('flndrn');
13 expect(ENTERPRISE_LEGAL_TEMPLATES.dpa.typesOfData.length).toBeGreaterThan(2);
14 });
15
16 test('retention + security overviews exist', () => {
17 expect(ENTERPRISE_LEGAL_TEMPLATES.retention.customerControls.length).toBeGreaterThan(0);
18 const joined = ENTERPRISE_LEGAL_TEMPLATES.securityOverview.bullets.join(' ');
19 expect(joined).toMatch(/SCIM|SSO|TLS/i);
20 });
21
22 test('HIPAA outline is marked template', () => {
23 expect(ENTERPRISE_LEGAL_TEMPLATES.hipaaBaaOutline.status).toBe('template_outline');
24 });
25});