Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/2-features/FS-1002
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Allow deletion of MLS team conversations
2 changes: 1 addition & 1 deletion libs/wire-api/src/Wire/API/Conversation/Protocol.hs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ protocolValidAction ProtocolProteus _ = True
protocolValidAction (ProtocolMLS _) ConversationJoinTag = False
protocolValidAction (ProtocolMLS _) ConversationLeaveTag = True
protocolValidAction (ProtocolMLS _) ConversationRemoveMembersTag = False
protocolValidAction (ProtocolMLS _) ConversationDeleteTag = False
protocolValidAction (ProtocolMLS _) ConversationDeleteTag = True
protocolValidAction (ProtocolMLS _) _ = True

instance ToSchema ProtocolTag where
Expand Down
23 changes: 23 additions & 0 deletions services/galley/test/integration/API/MLS.hs
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ tests s =
[ test s "fail to create MLS conversation" postMLSConvFail,
test s "create MLS conversation" postMLSConvOk
],
testGroup
"Deletion"
[ test s "delete a MLS conversation" testDeleteMLSConv
],
testGroup
"Commit"
[ test s "add user to a conversation" testAddUser,
Expand Down Expand Up @@ -1932,3 +1936,22 @@ testFederatedGetGroupInfo = do
err @?= ConvNotFound
GetGroupInfoResponseState _ ->
assertFailure "Unexpected success"

testDeleteMLSConv :: TestM ()
testDeleteMLSConv = do
localDomain <- viewFederationDomain
-- c <- view tsCannon
(tid, aliceUnq, [bobUnq]) <- API.Util.createBindingTeamWithMembers 2
let alice = Qualified aliceUnq localDomain
bob = Qualified bobUnq localDomain

runMLSTest $ do
[alice1, bob1] <- traverse createMLSClient [alice, bob]
void $ uploadNewKeyPackage bob1

(_, qcnv) <- setupMLSGroup alice1
commit <- createAddCommit alice1 [bob]
void $ sendAndConsumeCommitBundle commit

deleteTeamConv tid (qUnqualified qcnv) aliceUnq
!!! statusCode === const 200