|
|
@ -19,6 +19,8 @@ if (process.env.SAUCE_USERNAME !== undefined) {
|
|
|
|
driver.get('http://localhost:3000/assert/');
|
|
|
|
driver.get('http://localhost:3000/assert/');
|
|
|
|
var report = driver.wait(WebDriver.until.elementLocated(WebDriver.By.className("report")), 5000);
|
|
|
|
var report = driver.wait(WebDriver.until.elementLocated(WebDriver.By.className("report")), 5000);
|
|
|
|
report.getAttribute("class").then(function (cls) {
|
|
|
|
report.getAttribute("class").then(function (cls) {
|
|
|
|
|
|
|
|
report.getText().then(function (text) {
|
|
|
|
|
|
|
|
console.log("\n-----\n" + text + "\n-----");
|
|
|
|
driver.quit();
|
|
|
|
driver.quit();
|
|
|
|
if (!cls) {
|
|
|
|
if (!cls) {
|
|
|
|
throw new Error("cls is null");
|
|
|
|
throw new Error("cls is null");
|
|
|
@ -28,3 +30,4 @@ report.getAttribute("class").then(function (cls) {
|
|
|
|
throw new Error("cls does not contain the word success");
|
|
|
|
throw new Error("cls does not contain the word success");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
});
|
|
|
|