You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.1 KiB
42 lines
1.1 KiB
const selenium = require('selenium-webdriver');
|
|
const delay = (ms) => {
|
|
return new Promise((resolve) => {
|
|
setTimeout(resolve, ms);
|
|
});
|
|
}
|
|
|
|
const main = async ()=> {
|
|
const driver = await new selenium.Builder().forBrowser('chrome').build();
|
|
await driver.get('https://outcomes.generalassemb.ly/');
|
|
|
|
let selection = selenium.By.id('identify_email');
|
|
let element = driver.findElement(selection);
|
|
element.sendKeys('matt.huntington@generalassemb.ly');
|
|
|
|
selection = selenium.By.id('baseForm');
|
|
element = driver.findElement(selection);
|
|
element.submit();
|
|
|
|
await delay(2000);
|
|
|
|
selection= selenium.By.css('input[type="text"]');
|
|
element = await driver.findElement(selection);
|
|
element.sendKeys('matt.huntington@generalassemb.ly');
|
|
|
|
selection= selenium.By.css('input[type="password"]');
|
|
element = await driver.findElement(selection);
|
|
element.sendKeys('Hunt!ngt0n80!');
|
|
|
|
selection = selenium.By.css('form');
|
|
element = driver.findElement(selection);
|
|
element.submit();
|
|
|
|
await delay(2000);
|
|
|
|
selection= selenium.By.css('a')
|
|
element = await driver.findElements(selection);
|
|
|
|
element[1].click();
|
|
}
|
|
main();
|