nicer output, comment

pull/21833/head
Bruno Windels 2019-04-03 14:37:03 +02:00
parent e147cc9341
commit e10e4b0eab
1 changed files with 2 additions and 1 deletions

View File

@ -39,9 +39,10 @@ module.exports = async function e2eEncryptionScenarios(alice, bob) {
bob.log.step(`starts SAS verification with ${alice.username}`);
const bobSasPromise = startSasVerifcation(bob, alice.username);
const aliceSasPromise = acceptSasVerification(alice, bob.username);
// wait in parallel, so they don't deadlock on each other
const [bobSas, aliceSas] = await Promise.all([bobSasPromise, aliceSasPromise]);
assert.deepEqual(bobSas, aliceSas);
bob.log.done(`done, (${bobSas.join(", ")}) matches!`);
bob.log.done(`done (match for ${bobSas.join(", ")})`);
const aliceMessage = "Guess what I just heard?!"
await sendMessage(alice, aliceMessage);
await receiveMessage(bob, {sender: "alice", body: aliceMessage, encrypted: true});