Revert ES6ification of end-to-end tests and add instructions for Windows

Because the tests are run directly by node, we have to use the CommonJS module syntax. We could run the thing through babel, but then we just have another babel.

Windows instructions are from experience and may not be optimized.
This commit is contained in:
Travis Ralston 2020-01-10 10:13:41 -07:00
parent 9f04f94c65
commit e66f2a6c3f
24 changed files with 103 additions and 52 deletions

View file

@ -38,7 +38,7 @@ async function getSasCodes(session) {
return sasLabels;
}
export async function startSasVerifcation(session, name) {
module.exports.startSasVerifcation = async function(session, name) {
await startVerification(session, name);
// expect "Verify device" dialog and click "Begin Verification"
await assertDialog(session, "Verify device");
@ -51,9 +51,9 @@ export async function startSasVerifcation(session, name) {
// click "Got it" when verification is done
await acceptDialog(session);
return sasCodes;
}
};
export async function acceptSasVerification(session, name) {
module.exports.acceptSasVerification = async function(session, name) {
await assertDialog(session, "Incoming Verification Request");
const opponentLabelElement = await session.query(".mx_IncomingSasDialog_opponentProfile h2");
const opponentLabel = await session.innerText(opponentLabelElement);
@ -67,4 +67,4 @@ export async function acceptSasVerification(session, name) {
// click "Got it" when verification is done
await acceptDialog(session);
return sasCodes;
}
};