Created
July 30, 2021 21:25
-
-
Save efleming969/dc6a504d49a611067a017ec7a2eeab3e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* ==================== */ | |
const codeInput = await page.$( | |
`//input[@aria-labelledby = (//*[text() = 'Code']/@id) or @id = (//*[text() = 'Code']/@for)]` ) | |
await codeInput.type( "111111" ) | |
await page.click( `//button[text() = 'Fetch game data']` ) | |
await page.waitForSelector( `//*[@aria-label='list of players']` ) | |
await page.click( `//input[@aria-labelledby = (//*[text() = 'joe']/@id) or @id = (//*[text() = 'joe']/@for)]` ) | |
await page.click( `//button[@type = 'submit' and text() = 'Submit']` ) | |
const alert = await page.waitForSelector( `//*[@role = 'alert' and @aria-label = 'confirmation']` ) | |
expect( await alert.textContent() ).to.eq( "Your game was submitted!" ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment