Updated check for Login Button

This commit is contained in:
2024-10-02 14:39:49 -07:00
parent c9186192cd
commit 10ffc73fcf
4 changed files with 244 additions and 121 deletions

Binary file not shown.

355
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -12,7 +12,7 @@
"author": "", "author": "",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"chromedriver": "^126.0.4", "chromedriver": "^129.0.2",
"express": "^4.19.2", "express": "^4.19.2",
"geckodriver": "^4.4.1", "geckodriver": "^4.4.1",
"nodemon": "^3.1.0", "nodemon": "^3.1.0",

View File

@@ -85,13 +85,13 @@ const ExACT_landingPage = (req, res) => {
} }
// Check if landing page test was successful // Check if landing page test was successful
const logoutButton = await driver.wait(until.elementLocated(By.id('headerContainer')), 5000).catch(() => false); const loginButton = await driver.wait(until.elementLocated(By.css('.login')), 5000).catch(() => false);
if (logoutButton) { if (loginButton) {
console.log('Login successful'); console.log('Login button present');
testStatus = 'Passed'; testStatus = 'Passed';
} else { } else {
console.log('Login failed'); console.log('Login button not found');
} }
// Log test end time // Log test end time