test: 실제 transport 권한과 커맨드 내구 행렬을 검증한다

실제 Fastify HTTP, PostgreSQL과 Redis에서 예약 mutation의 인증·sanction·소유권·수뇌 경계, 감사 원장과 무부작용을 검증한다.

장수 55개와 수뇌 35개를 R1/R2/R3으로 전수 분류하고 대표 9개를 Ref/Core 의미 비교부터 lease, 단일 flush와 fresh reload까지 실행한다. 비행위자 revision/lease와 관직 5 수뇌 partition도 exact 보존한다.
This commit is contained in:
2026-08-24 07:41:12 +00:00
parent c82c076b1b
commit 8d966d3152
8 changed files with 3078 additions and 50 deletions
@@ -39,6 +39,13 @@ const databaseSnapshot = (
cityId: 1,
troopId: 1,
userId: 'owner-a',
personalCode: 'che_안전',
specialCode: 'che_농업',
special2Code: 'che_신산',
horseCode: 'che_명마_01_적토마',
weaponCode: 'che_무기_07_맥궁',
bookCode: 'che_서적_01_손자병법',
itemCode: 'che_도구_01_옥새',
meta: commandStateFixture?.generalMeta ?? {},
penalty: {},
...commandStateFixture?.generalFields,
@@ -92,6 +99,18 @@ const databaseSnapshot = (
});
describe('turn snapshot canonical blind-spot coverage', () => {
it('projects Prisma general role and item column names into canonical fields', () => {
expect(databaseSnapshot().generals[0]).toMatchObject({
personality: 'che_안전',
specialDomestic: 'che_농업',
specialWar: 'che_신산',
itemHorse: 'che_명마_01_적토마',
itemWeapon: 'che_무기_07_맥궁',
itemBook: 'che_서적_01_손자병법',
itemExtra: 'che_도구_01_옥새',
});
});
it('projects troop rows and detects a troop mutant', () => {
const reference = databaseSnapshot();
const core = {