Skip to content

Conversation

erikjohnston
Copy link
Member

@kegsay
Copy link
Member

kegsay commented Aug 15, 2025

Very sensible, I'm surprised we didn't!

erikjohnston and others added 2 commits August 22, 2025 13:30
Co-authored-by: Eric Eastwood <erice@element.io>
Co-authored-by: Eric Eastwood <erice@element.io>
"invite": []string{bob.UserID},
})
bob.MustSyncUntil(t, client.SyncReq{}, client.SyncInvitedTo(bob.UserID, roomID))
alice.MustDo(t, "POST", []string{"_matrix", "client", "v3", "rooms", roomID, "kick"},
Copy link
Collaborator

@MadLittleMods MadLittleMods Aug 26, 2025

Choose a reason for hiding this comment

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

It would be good to have a test where someone else rescinds the invite (someone different than the inviter)

Also a test for someone else from another server in the room

Copy link
Collaborator

Choose a reason for hiding this comment

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

Test was added for the first case but not the second for someone else from another server in the room

bob.MustSyncUntil(t, client.SyncReq{Filter: includeLeaveSyncFilter}, client.SyncLeftFrom(bob.UserID, roomID))
})

t.Run("Non-invitee user cannot rescind invite over federation", func(t *testing.T) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
t.Run("Non-invitee user cannot rescind invite over federation", func(t *testing.T) {
t.Run("Non-inviter user cannot rescind invite over federation", func(t *testing.T) {

Comment on lines +195 to +196
// Alice, not the original inviter, kicks bob. This does not result
// in bob seeing the rescission.
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should comment that it would be fine for bob to see the rescission but they have no way to auth it because of X so they can't take it into account

"invite": []string{bob.UserID},
})
bob.MustSyncUntil(t, client.SyncReq{}, client.SyncInvitedTo(bob.UserID, roomID))
alice.MustDo(t, "POST", []string{"_matrix", "client", "v3", "rooms", roomID, "kick"},
Copy link
Collaborator

Choose a reason for hiding this comment

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

Test was added for the first case but not the second for someone else from another server in the room

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants