Fluent Commerce Logo
Docs

Core Module 2.3.1 - Test Utilities Support for Cross-Workflow Events

Release

Author:

Holger Lierse

Changed on:

12 Nov 2026

Target release date:2026-11-13
Release status:Released

Description

Core Module 2.3.1 fixes the `@RuleInfo.produces` validation in the Test Utilities for rules that send cross-workflow events. Before, `TestUtils.validateEventAgainstProduces` rejected these events with "produced an event it hasn't declared in the @RuleInfo.produces annotation", even when the declaration was correct, so tests for these rules had to be disabled.`util-test` is a test dependency, so rules running on the platform aren't affected.

Changelog

Test Utilities
  • `@RuleInfo.produces` is now validated the way the platform reads it:
    • A blank `entityType` or `entitySubtype` matches any value, including none
    • `EVENT_TYPE`, `EVENT_SUBTYPE` and the `{event.entityType}`, `{event.entitySubtype}` and `{event.status}` templates resolve against the event that triggered the rule. In a workflow, that's the event of the current step
    • Any other value is rendered against the rule's props, as before
  • `WorkflowExecutor` validates each rule only against the events it produced
  • New `validateEventAgainstProduces` overload with a `firstEventIndex` argument
  • Rule props used in a `produces` declaration (for example `eventName = "{eventName}"`) are now inserted as they are, so values containing `$` or `\` no longer make the check fail
Core Utilities, Dynamic Utilities

Limitations

  • A blank `entitySubtype` is no longer checked against the triggering entity. To keep checking the subtype, declare `entitySubtype = EVENT_SUBTYPE`.
Released capability depth:Fix
Release bundle / Capability type:Module