Hot answers tagged

4 votes

Protractor - How to use async/await

Where to use async-await in Protractor scripts? Async/await statements are only required in places where promise resolution is occurring before moving to the next statement so yes, it is only ...
Vishal Aggarwal's user avatar
4 votes

driver.manage(...).timeouts is not a function

"chromedriver": "^2.36.0", "selenium-webdriver": "^4.0.0-alpha.1", here example of create driver function: import webdriver from 'selenium-webdriver' import chrome from 'selenium-webdriver/chrome' ...
artem gruden's user avatar
2 votes

WebdriverIO browser.scroll() always scrolls to the top?

We now have an API for this. See scroll into view
ady's user avatar
  • 21
2 votes

driver.manage(...).timeouts is not a function

I had a same issue. It is due to a version issue. You can use: driver.manage().setTimeouts() or driver.sleep() please, check the documentation for more details.
simbawow's user avatar
2 votes

What tool combination is best to build web based UI for Selenium framework

Remark: Applet is a bad idea since they are considered outdated technology by a lot of people and are not supported by some modern browsers. Search around about the issue, but here is the sample ...
Alexey R.'s user avatar
  • 11.6k
2 votes

WebDriverIO executing too fast

WebdriverIO is Javascript based automation framework that follows an asynchronous execution approach and consequently, webdriver's execution speed doesn't match. We as an automation testing services ...
Anand's user avatar
  • 785
2 votes

Getting "element not interactable: element not interactable" error when trying to upload file using Webdriver.IO

Changing the method from "setValue" to "addValue" helped me resolve the issue. await fileUpload_var.addValue(remoteFilePath)
Seema Nair's user avatar
2 votes
Accepted

Playwright: Implementing Page Object Patter into Framework

Have you tried to run it? constructor(page) { this.page = page; } and later: module.exports = new SearchPage(); What about that missing page? this.page in the object will be undefined, so none ...
pavelsaman's user avatar
  • 4,548
2 votes

Getting an error TypeError: describe is not a function

var Page = require ('../lib/home_page.js'); var webdriver = require('selenium-webdriver'); { describe , before , after , it } require('selenium-webdriver/testing'); var page; describe('...
Dmytro Lukashenko's user avatar
2 votes
Accepted

What tool combination is best to build web based UI for Selenium framework

Jenkins "build now" can run any (Jenkins) test on demand. Because that URL is fixed (per project), you can create a HTML page with those URLs. If you use wiki, it would be trivial to create such ...
Peter M. - stands for Monica's user avatar
1 vote
Accepted

What is the best way to set up multiple tests on one webpage with Selenium Webdriver and Cucumber JS?

Welcome to the world of automated testing. There generally isn't a 'right' answer to your question and a lot of it comes down to personal preference, however I will break it down and approach it with ...
Cameron Fairburn's user avatar
1 vote

Unit Tests or Integration Tests for validating file contents

Whether you need to add the JSON file validation as a unit test or an integration test depends on the nature of the validation. Unit tests check the functionality of individual units of code in ...
IAmMilinPatel's user avatar
1 vote

What tool combination is best to build web based UI for Selenium framework

You should be able to do this reasonably easily if you define your jenkins jobs using groovy pipeline syntax and install the blue ocean modules into jenkins , its a much slicker interface than ...
Amias's user avatar
  • 1,202
1 vote

validated variable is present and datatype assertion using Jest testing

Your admin.js is : const mongoose = require("mongoose"); let Schema = mongoose.Schema; Schema = new Schema({ User: { type: String, unique: true }, Pass: { type: String }, }); var ...
PDHide's user avatar
  • 11.1k
1 vote

How to download files in folder other then the download folder using Protractor?

Your code is working fine , which protractor version are you using. Try using full path as mentioned in other answer and also try replacing CHromeoptions with googchromeOptions if first is nt working (...
PDHide's user avatar
  • 11.1k
1 vote

How to download files in folder other then the download folder using Protractor?

The ChromeDriver documentation states "Relative paths do not always work. For best result, use full path instead.". Explanation why it's not always working is lacking though. Using an ...
Bouke's user avatar
  • 202
1 vote

How to drag and drop the image using dragAnddrop() in javascript using selenium webdriver?

here is my code that i used to drag elements from one area to another, the only thing that you would need to do is figure out what you would define as 'elementDestination' which can be an area of ...
Jack Williams's user avatar
1 vote

NodeJS Selenium-webdriver firefox geckodriver set browser binary location without changing PATH

I found the answer Turns out in options.. you're supposed to point to firefox.exe itself, not just the path const firefox = require('selenium-webdriver/firefox'); let options = new firefox....
Malcolm Salvador's user avatar
1 vote
Accepted

Nodejs Selenium-webdriver Selecting Particular <select> element if there are 2 elements that have the same ID

You almost had it. The first match is [1] not [0]. Change your line to: element = await driver.findElement(By.xpath("//select[@id='SelectEU'][1]")); Edit: Regarding your second question in your ...
Bill Hileman's user avatar
1 vote

Testing nodejs gRPC client functions

There is no sync alternative i could find for that method, so you could validate everything inside the callback itself or wrap it with a promise: let authenticateSync = function (request, meta) {...
PDHide's user avatar
  • 11.1k
1 vote

How to fix "Cannot find module" error and "Error: ReferenceError: Element is not defined" in protractor?

In your LoginTest.js , you have given incorrect reference of page object. change it to: var logins = require('../../pageObjects/login.po.js'); and then you do not need to create a page object, ...
Pankaj Dubey's user avatar
1 vote

How to stress test a web application relying on Socket.IO?

You'd do it pretty much the same way you'd load test other interfaces for servers. You need a client that interacts with the server and a way to generate a lot of actions concurrently and for some ...
Cherree's user avatar
  • 1,189
1 vote

How to explicity fail e2e tests on unexpected behavior?

Implement exception handling. The solution in these scenarios which worked for me is, checking for console errors on each form submissions( post requests) and raising the JavaScript error which needs ...
Vishal Aggarwal's user avatar
1 vote

MQTT QoS automated testing with aedes broker on node.js/net

Since what I want to test is not really the connection but how the client responds to undelivered acknowledgements, a possible way to approach this would be, once the broker publishes the message to ...
seek88's user avatar
  • 61
1 vote

Mocking external endpoints in tests on open source project

IMHO, firstly, you should create JSON schema to test all your JSON files in an actual state with this JSON schema. This is very important to keep the structure of JSON in the correct way. Secondly, ...
OlegDovger's user avatar
1 vote

When I tried to install opencv4nodejs I am getting an error

Looking at your error after running "appium-doctor" I will say please remove white spaces from all path which you are using. [Mandatory] I referred earlier this link to have correct ...
Narendra Chandratre's user avatar
1 vote

Selenium steps not running in order of promise

It would be recommended to use await instead of having sleeps: var _wait_and_input = async function(element_type, descriptor, keys, message) { let element = element_type(descriptor); ...
PDHide's user avatar
  • 11.1k
1 vote

driver.manage(...).timeouts is not a function

Since version v4.0.0-alpha.1 the timeouts() has been changed into setTimeouts(). API Changes: Changes to lib/webdriver.Options (driver.manage()): Removed timeouts (use get/setTimeouts) ...
Niels van Reijmersdal's user avatar
1 vote

driver.manage(...).timeouts is not a function

I was having the same problem and this fixed it: const capabilities = await driver.getCapabilities(); capabilities['map_'].set('timeouts', { implicit: TIMEOUT, pageLoad: TIMEOUT, script: TIMEOUT }); ...
E Keane's user avatar
  • 11
1 vote

How different it is to manually test a web application which is developed using MEAN stack?

Manually testing the application developed using two different technologies don't have any key differences. In manual testing, you are going to concentrate on the functionality flow, UI based on user ...
Ranjani's user avatar
  • 316

Only top scored, non community-wiki answers of a minimum length are eligible