Skip to content

Support passing preconfigured messages when testing Subscribers#19

Merged
DanielBadura merged 1 commit intopatchlevel:1.4.xfrom
fritz-gerneth:issue-18
Feb 10, 2026
Merged

Support passing preconfigured messages when testing Subscribers#19
DanielBadura merged 1 commit intopatchlevel:1.4.xfrom
fritz-gerneth:issue-18

Conversation

@fritz-gerneth
Copy link
Contributor

Resolves #18

Copy link
Member

@DavidBadura DavidBadura left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I just have one small request.

@DavidBadura DavidBadura added this to the 1.4.0 milestone Feb 9, 2026
@DavidBadura DavidBadura added the enhancement New feature or request label Feb 9, 2026
@fritz-gerneth fritz-gerneth force-pushed the issue-18 branch 2 times, most recently from 1707b09 to a9f56da Compare February 10, 2026 06:36
@DanielBadura
Copy link
Member

Lowest tests are failing due to not handling the RecordedOnHeader pre version 3.13.0. e.g. in 3.10.x as used in the tests: https://github.com/patchlevel/event-sourcing/blob/3.10.x/src/Subscription/Subscriber/ArgumentResolver/RecordedOnArgumentResolver.php#L14-L17

I would say, bump the event-sourcing dep to ^3.13.0 as this is the first version supporting the header in the resolver: https://github.com/patchlevel/event-sourcing/blob/3.13.x/src/Subscription/Subscriber/ArgumentResolver/RecordedOnArgumentResolver.php#L15-L22

Other option would be to use the AggregateHeader instead in the test.

@fritz-gerneth
Copy link
Contributor Author

Other option would be to use the AggregateHeader instead in the test.

I read that class / approach as somewhat deprecated over using dedicated headers?

@DanielBadura
Copy link
Member

Yes, AggregateHeader is already removed in the 4.0.x branch. But we don't need to account this here currently imho. We can adjust this as soon this package only supports the new major version.

@DanielBadura DanielBadura merged commit d8e7ffd into patchlevel:1.4.x Feb 10, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cannot test subscribers with $recordedOn and custom headers

3 participants