Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
limonte committed Nov 7, 2021
1 parent ac25d44 commit f80ab4b
Showing 1 changed file with 2 additions and 15 deletions.
17 changes: 2 additions & 15 deletions test/source/tests/page-recipe/compose-page-recipe.ts
Expand Up @@ -8,7 +8,6 @@ import { EvaluateFn } from 'puppeteer';
import { PageRecipe } from './abstract-page-recipe';
import { Util } from '../../util';
import { expect } from 'chai';
import { Page } from 'puppeteer';

type RecipientType = "to" | "cc" | "bcc";
type Recipients = {
Expand Down Expand Up @@ -107,23 +106,11 @@ export class ComposePageRecipe extends PageRecipe {
}

public static waitWhenDraftIsSaved = async (composePageOrFrame: Controllable) => {
try {
await composePageOrFrame.verifyContentIsPresentContinuously('@send-btn-note', 'Saved');
} catch (e) {
console.log('waitWhenDraftIsSaved');
console.log(e);
console.log(await (composePageOrFrame.target as Page).screenshot({ encoding: 'base64' }));
}
await composePageOrFrame.verifyContentIsPresentContinuously('@send-btn-note', 'Saved');
}

public static waitWhenDraftIsSavedLocally = async (composePageOrFrame: Controllable) => {
try {
await composePageOrFrame.verifyContentIsPresentContinuously('@send-btn-note', 'Draft saved locally (offline)');
} catch (e) {
console.log('waitWhenDraftIsSaved');
console.log(e);
console.log(await (composePageOrFrame.target as Page).screenshot({ encoding: 'base64' }));
}
await composePageOrFrame.verifyContentIsPresentContinuously('@send-btn-note', 'Draft saved locally (offline)');
}

public static sendAndClose = async (
Expand Down

0 comments on commit f80ab4b

Please sign in to comment.