From 4dfa4616136dea180d76cddf95036f1c6340f66e Mon Sep 17 00:00:00 2001 From: Rasmus Rendal Date: Tue, 27 Oct 2026 09:20:59 +0100 Subject: [PATCH] fix(TestIsDirectFlagFederation): Include `m.room.create` in invite state In MSC4311 and since spec version 1.16, invites are expected to contain the `m.room.create` event in the `invite_room_state` field. But the Complement test `TestIsDirectFlagFederation` does not contain this event, causing Arminius to fail when checking for the event. This commit includes the create event in `invite_room_state` of the invite request. Signed-off-by: Rasmus Rendal --- tests/direct_messaging_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/direct_messaging_test.go b/tests/direct_messaging_test.go index bb06ae795..2ca93a1a3 100644 --- a/tests/direct_messaging_test.go +++ b/tests/direct_messaging_test.go @@ -130,7 +130,8 @@ func TestIsDirectFlagFederation(t *testing.T) { "is_direct": true, }, }) - inviteReq, err := fclient.NewInviteV2Request(dmInviteEvent, []gomatrixserverlib.InviteStrippedState{}) + createEvent := room.Timeline[0] + inviteReq, err := fclient.NewInviteV2Request(dmInviteEvent, []gomatrixserverlib.InviteStrippedState{gomatrixserverlib.NewInviteStrippedState(createEvent)}) if err != nil { t.Fatalf("failed to make invite request: %s", err) }