Skip to content

Instantly share code, notes, and snippets.

@prettydiff
Created August 5, 2016 20:18
Show Gist options
  • Save prettydiff/8ca682cb042e2220a40ad01518eb4581 to your computer and use it in GitHub Desktop.
Save prettydiff/8ca682cb042e2220a40ad01518eb4581 to your computer and use it in GitHub Desktop.
var expWebTest = (function () {
var test = function () {
/*var delay = function (testExpression, callback) {
if (testExpression === true) {
return setTimeout(function () {
console.log("test delay");
delay(node, callback);
}, 100);
}
console.clear();
console.log("delay complete");
callback();
};
delay(document.getElementsByTagName("body")[0] === null, function () {
setTimeout(function () {
console.log("asdfasdf");
}, 30000);
});*/
alert("asdf asdf asdf");
},
webdriver = require("selenium-webdriver"),
By = webdriver.by,
until = webdriver.until,
driver = new webdriver.Builder().forBrowser("firefox").build();
driver.get("internal URL"); //I am using an actual URL here
driver.executeScript(test);
}());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment