From ff41ab3d6ce0f2b444a39d4f33b0b63778482618 Mon Sep 17 00:00:00 2001 From: unanmed <1319491857@qq.com> Date: Wed, 9 Sep 2026 00:19:47 +0800 Subject: [PATCH] test(01-07): cover complete event mode matrix - Verify unmatched triggers do not affect cut or reduction results. - Cover unknown ids, hook trigger mapping, coordinates, and source environments. --- .../data-system/src/event/eventDispatch.test.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages-user/data-system/src/event/eventDispatch.test.ts b/packages-user/data-system/src/event/eventDispatch.test.ts index 353181e..dc73dd2 100644 --- a/packages-user/data-system/src/event/eventDispatch.test.ts +++ b/packages-user/data-system/src/event/eventDispatch.test.ts @@ -346,6 +346,18 @@ describe('event execute modes and reductions', () => { { custom: {} } ) ).resolves.toBe(false); + fixture.executor.setReduce(modules.EventReduceMode.OrReduce); + await expect( + fixture.executor.execute([invocation('wrong-trigger', enter)], { + custom: {} + }) + ).resolves.toBe(false); + fixture.executor.setReduce(modules.EventReduceMode.AndReduce); + await expect( + fixture.executor.execute([invocation('wrong-trigger', enter)], { + custom: {} + }) + ).resolves.toBe(true); }); it('warns for unknown ids and continues with valid events', async () => {