Fix assert vs assert.equal

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Michael Telatynski 2020-05-27 13:39:00 +01:00
parent faaca43a75
commit 841ce74ac2
2 changed files with 2 additions and 2 deletions

View file

@ -20,7 +20,7 @@ const assert = require('assert');
async function assertDialog(session, expectedTitle) { async function assertDialog(session, expectedTitle) {
const titleElement = await session.query(".mx_Dialog .mx_Dialog_title"); const titleElement = await session.query(".mx_Dialog .mx_Dialog_title");
const dialogHeader = await session.innerText(titleElement); const dialogHeader = await session.innerText(titleElement);
assert(dialogHeader, expectedTitle); assert.equal(dialogHeader, expectedTitle);
} }
async function acceptDialog(session, expectedTitle) { async function acceptDialog(session, expectedTitle) {

View file

@ -24,7 +24,7 @@ async function assertNoToasts(session) {
async function assertToast(session, expectedTitle) { async function assertToast(session, expectedTitle) {
const h2Element = await session.query('.mx_Toast_title h2'); const h2Element = await session.query('.mx_Toast_title h2');
const toastTitle = await session.innerText(h2Element); const toastTitle = await session.innerText(h2Element);
assert(toastTitle, expectedTitle); assert.equal(toastTitle, expectedTitle);
} }
async function acceptToast(session, expectedTitle) { async function acceptToast(session, expectedTitle) {