Skip to content
Merged
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
10 changes: 10 additions & 0 deletions integration/test/Test/MLS/One2One.hs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ import API.Galley
import qualified Data.ByteString.Base64 as Base64
import qualified Data.ByteString.Char8 as B8
import qualified Data.Set as Set
import qualified Data.Text as T
import qualified Data.Text.Read as T
import MLS.Util
import Notifications
import SetupHelpers
Expand Down Expand Up @@ -257,3 +259,11 @@ testMLSOne2One suite scenario = do
let isMessage n = nPayload n %. "type" `isEqual` "conversation.mls-message-add"
n <- awaitMatch isMessage ws
nPayload n %. "data" `shouldMatch` B8.unpack (Base64.encode mp.message)

-- Send another commit. This verifies that the backend has correctly updated
-- the cipersuite of this conversation.
void $ createPendingProposalCommit alice1 >>= sendAndConsumeCommitBundle

conv' <- getMLSOne2OneConversation alice bob >>= getJSON 200
(suiteCode, _) <- assertOne $ T.hexadecimal (T.pack suite.code)
conv' %. "cipher_suite" `shouldMatchInt` suiteCode