Skip to content

Commit

Permalink
[JS] Fix JS test
Browse files Browse the repository at this point in the history
  • Loading branch information
harsha509 committed May 23, 2024
1 parent e3fadcc commit 9fed885
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
16 changes: 8 additions & 8 deletions examples/javascript/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions examples/javascript/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
"name": "javascript-examples",
"version": "1.0.0",
"scripts": {
"test": "npx mocha test/**/*.spec.js --timeout 60000"
"test": "npx mocha test/**/keysTest.spec.js --timeout 60000"
},
"author": "The Selenium project",
"license": "Apache-2.0",
"dependencies": {
"assert": "2.1.0",
"selenium-webdriver": "4.20.0"
"selenium-webdriver": "4.21.0"
},
"devDependencies": {
"mocha": "10.4.0"
Expand Down
4 changes: 2 additions & 2 deletions examples/javascript/test/waits/waits.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const { By, Browser, until } = require('selenium-webdriver');
const assert = require("node:assert");

suite(function (env) {
describe('Element Interactions', function () {
describe('Waits', function () {
let driver;

before(async function () {
Expand Down Expand Up @@ -47,7 +47,7 @@ suite(function (env) {
await driver.get('https://www.selenium.dev/selenium/web/dynamic.html');
let revealed = await driver.findElement(By.id("revealed"));
await driver.findElement(By.id("reveal")).click();
await driver.wait(until.elementIsDisabled(revealed), 2000);
await driver.wait(until.elementIsVisible(revealed), 2000);
await revealed.sendKeys("Displayed");
assert.equal(await revealed.getAttribute("value"), "Displayed")
})
Expand Down

0 comments on commit 9fed885

Please sign in to comment.