This commit is contained in:
23
src/services/storyEngine/authorialConstraintPack.test.ts
Normal file
23
src/services/storyEngine/authorialConstraintPack.test.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
|
||||
import { buildAuthorialConstraintPack } from './authorialConstraintPack';
|
||||
|
||||
describe('authorialConstraintPack', () => {
|
||||
it('builds authorial rules from profile context', () => {
|
||||
const pack = buildAuthorialConstraintPack({
|
||||
profile: {
|
||||
coreConflicts: ['封桥旧案再起'],
|
||||
themePack: {
|
||||
toneRange: ['紧张', '克制'],
|
||||
},
|
||||
storyGraph: {
|
||||
visibleThreads: [{ title: '封桥旧案' }],
|
||||
scars: [{ title: '断桥旧痕' }],
|
||||
},
|
||||
} as never,
|
||||
});
|
||||
|
||||
expect(pack.toneRules).toContain('紧张');
|
||||
expect(pack.requiredPayoffs).toContain('封桥旧案');
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user