You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
714 B
TypeScript
21 lines
714 B
TypeScript
import { Page } from '@playwright/test';
|
|
import {
|
|
clickOnTestIdWithText,
|
|
hasElementPoppedUpThatShouldnt,
|
|
typeIntoInput,
|
|
waitForLoadingAnimationToFinish,
|
|
} from '../utilities/utils';
|
|
|
|
export async function logIn(window: Page, recoveryPhrase: string) {
|
|
await clickOnTestIdWithText(window, 'link-device');
|
|
await typeIntoInput(window, 'recovery-phrase-input', recoveryPhrase);
|
|
await clickOnTestIdWithText(window, 'continue-session-button');
|
|
await waitForLoadingAnimationToFinish(window, 'loading-spinner', 5000);
|
|
await hasElementPoppedUpThatShouldnt(
|
|
window,
|
|
'data-testid',
|
|
'session-toast',
|
|
'Could not find your display name. Please Sign In by Restoring Your Account instead.'
|
|
);
|
|
}
|