Add Lightbox integration test

This commit is contained in:
Jamie Kyle 2024-09-09 15:43:59 -07:00 committed by GitHub
parent 4f9d383180
commit bdbc63ccf0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 343 additions and 85 deletions

View file

@ -23,7 +23,11 @@ import {
RECEIPT_BATCHER_WAIT_MS,
} from '../../types/Receipt';
import { sleep } from '../../util/sleep';
import { expectSystemMessages, typeIntoInput } from '../helpers';
import {
expectSystemMessages,
typeIntoInput,
waitForEnabledComposer,
} from '../helpers';
export const debug = createDebug('mock:test:pni-signature');
@ -147,7 +151,7 @@ describe('pnp/PNI Signature', function (this: Mocha.Suite) {
}
debug('Enter first message text');
{
const compositionInput = await app.waitForEnabledComposer();
const compositionInput = await waitForEnabledComposer(window);
await typeIntoInput(compositionInput, 'first');
await compositionInput.press('Enter');
@ -175,7 +179,7 @@ describe('pnp/PNI Signature', function (this: Mocha.Suite) {
}
debug('Enter second message text');
{
const compositionInput = await app.waitForEnabledComposer();
const compositionInput = await waitForEnabledComposer(window);
await typeIntoInput(compositionInput, 'second');
await compositionInput.press('Enter');
@ -209,7 +213,7 @@ describe('pnp/PNI Signature', function (this: Mocha.Suite) {
debug('Enter third message text');
{
const compositionInput = await app.waitForEnabledComposer();
const compositionInput = await waitForEnabledComposer(window);
await typeIntoInput(compositionInput, 'third');
await compositionInput.press('Enter');
@ -373,7 +377,7 @@ describe('pnp/PNI Signature', function (this: Mocha.Suite) {
{
debug('Wait for composition input to clear');
const compositionInput = await app.waitForEnabledComposer();
const compositionInput = await waitForEnabledComposer(window);
debug('Enter an ACI message text');
await typeIntoInput(compositionInput, 'Hello ACI');