mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2024-11-27 09:35:56 -05:00
Create waitUntilVisible SeleniumHelper function for Jest tests.
This commit is contained in:
parent
bbfbf8d731
commit
6992ca707f
2 changed files with 6 additions and 1 deletions
|
@ -199,6 +199,10 @@ class SeleniumHelper {
|
|||
return false;
|
||||
}
|
||||
|
||||
async waitUntilVisible (element, driver) {
|
||||
await driver.wait(until.elementIsVisible(element));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
module.exports = SeleniumHelper;
|
||||
|
|
|
@ -7,7 +7,8 @@ const {
|
|||
findByXpath,
|
||||
clickXpath,
|
||||
clickButton,
|
||||
buildDriver
|
||||
buildDriver,
|
||||
waitUntilVisible
|
||||
} = new SeleniumHelper();
|
||||
|
||||
let username = process.env.SMOKE_USERNAME;
|
||||
|
|
Loading…
Reference in a new issue