diff --git a/packages/e2e-assets/playwright/crx/assets.test.ts b/packages/e2e-assets/playwright/crx/assets.test.ts index 7f897f777..c50e6b323 100644 --- a/packages/e2e-assets/playwright/crx/assets.test.ts +++ b/packages/e2e-assets/playwright/crx/assets.test.ts @@ -15,16 +15,23 @@ test.describe('Check assets', () => { await page.getByRole('button', { name: 'Next: Seed Phrase' }).click(); const mnemonic = process.env.READONLY_TESTNET_ASSETS_VIEW; console.log(`Importing wallet with mnemonic: ${mnemonic}`); - const words = mnemonic.split(' '); - for (const [index, word] of words.entries()) { - console.log(`Filling word ${index + 1}: ${word}`); - const locator = page.locator('div').filter({ - hasText: new RegExp(`^${index + 1}$`), - }); - const input = locator.getByLabel('Type your text'); - await input.fill(word); - console.log(`Filled word ${index + 1}`); - } + + await page.evaluate(async (text) => { + await navigator.clipboard.writeText(text); + }, mnemonic); + + // const words = mnemonic.split(' '); + // for (const [index, word] of words.entries()) { + // console.log(`Filling word ${index + 1}: ${word}`); + // const locator = page.locator('div').filter({ + // hasText: new RegExp(`^${index + 1}$`), + // }); + // const input = locator.getByLabel('Type your text'); + // await input.fill(word); + // console.log(`Filled word ${index + 1}`); + // } + + await page.getByRole('button', { name: 'Paste seed phrase' }).click(); await page.getByRole('button', { name: 'Next: Your password' }).click(); await page.getByPlaceholder('Type your password').fill('qwe123QWE!@#');