Questions tagged [javascript]

JavaScript is a dialect of the standardized ECMAScript programming language, primarily used for scripting web-pages.

Filter by
Sorted by
Tagged with
1
vote
1answer
2k views

Rerun failed (flaky) tests with Jest

We are using Jest as our test runner for our JavaScript (React and Selenium) tests. We have one or two flaky tests (as TeamCity marks them flaky and we process them as technical-debt), although we ...
1
vote
1answer
11k views

Cannot load JDBC driver class 'com.mysql.jdbc.Driver' in Jmeter [closed]

When you running below Jmeter test plan then "Cannot load JDBC driver class 'com.mysql.jdbc.Driver' response message given. Can any one have any solution for this? Response code: null 0 Response ...
1
vote
3answers
16k views

How to find Scroll bar xpath?

I am working for a website automation testing. I need to scroll many times. How to find a Scroll bars`s Xpath in a browser ?
2
votes
2answers
946 views

How to test export functionality?

I have a scenario to test where I need to test that the export functionality is working properly or not. I know that usually in these cases, firstly we check the availability of file in location and ...
0
votes
3answers
874 views

How to Automate web services using JMETER?

How to Automate web services using JMETER? I need to check URL links are working and image are loading properly and with the response code given. see more details in below example, i just want to ...
10
votes
3answers
12k views

Why should we use javascript for UI test automation?

Background:JavaScript based automation frameworks heavily depends on asynchronous execution, promises, callbacks, anonymous functions, etc which are inherently complex and probably an overkill for a ...
1
vote
0answers
34 views

What are some recommended selenium strategies for deal with long list of input options that update a live preview? [closed]

I am testing an app that loads an email in an iframe. Next to the iframe is a long list of options (hundreds of options). Writing text in an option updates email text in the iframe. selecting a border ...
1
vote
1answer
3k views

((JavascriptExecutor)driver).executeScript(“scroll(0,1000)”); Not working on Selenium Webdriver 3 [duplicate]

No matter how many javscript executor lines I use or how many times I change the scrolling positions to different numbers, Selenium WebDriver 3 always takes me to the same place on the list that is ...
3
votes
0answers
137 views

When and where does Intern.js opens browser and how to open a new browser by using intern script

I'm trying my hands at intern.js to automate my UI test. And I want to some test to run on separate browser ,i.e open new browser run test run test close browser and so on but I'm unable to ...
1
vote
0answers
548 views

How to Wait until page is fully loaded with Intern js

I was trying to automate the UI testing of an application with Intern js. But I am having a problem finding the way to wait until the page is fully loaded. After researching for a while, I found ...
3
votes
1answer
546 views

WebDriver Error Cannot use 'in' operator to search for 'String' in false

I have been using selenium webdriver with protractor for more than a year now and recently after updating to the newest versions i got an error that i have never encountered before. As stated in the ...
1
vote
0answers
45 views

How to write a script for signup on spring boot with angularjs [closed]

Our project is on spring boot with docker using angularjs for front-end. We use protractor for front-end tests. I want to write a script for easy signup by giving parameters. How can I do this and ...
8
votes
2answers
855 views

Canonical way for multi-session browser testing in Protractor

The Question: What is the canonical way to write multi browser window tests in Protractor - the tests that involve multiple sessions fired up interacting with one another? The Story: The main ...
3
votes
1answer
396 views

How to get the x, y axis location of the view itself in selenium [closed]

How to get the x, y-axis location of the view itself in selenium? I know I can get the position of a specific element. But I can't find a way to get the coordinate of the window's view itself. So I ...
0
votes
1answer
977 views

How to click on an element in pop-up?

I want to click on the highlighted English Element but unable to click on that. Actually its a pop-up wind appear when i click on the some button. But my main concern is that I'm unable to click on ...
1
vote
2answers
4k views

How to check if a file with random changing name is downloaded using protractor selenium? [closed]

This is the path of file capabilities: { 'browserName': 'chrome', 'chromeOptions': { prefs: { download: { 'prompt_for_download': ...
2
votes
1answer
2k views

“Failed: Cannot read property 'isPresent' of undefined”

it('should be able to create a task for a product as a CTA', function () { browser.sleep(6222);browser.sleep(6222);console.log("ss"); productPage.productsTab.click(); expect(productPage....
2
votes
3answers
3k views

Protractor - Find delete button in <tr> with respect to <td> in other <tr>

In the web page, we have a number of rows (with row nested to it). The below code is a snippet for one such row. <tr ng-repeat="abc" class="alpha"> <td class="one ng-binding"> Apple &...
0
votes
3answers
5k views

How To Locate Element using selenium web driver when Unique property is 'index'?

How To Locate Elements using selenium web driver when only Unique value is 'index'? Resource-id,Class and Package are not unique. Below Layout taken from Android UI Automator Resource-id = android:...
0
votes
1answer
225 views

Jasmine web services automation “getting started” doc

I have been working on nightwatchjs from past 6 months, before that I was using Selenium-WebDriver to do browser automation. I have syntactical knowledge of JS and I assume that Jasmine won't bother ...
1
vote
1answer
202 views

Usage of javascriptexecutor in automation test scripts

I am creating a script for saving a record. There is a save button and it has an ID and javascript in it. Below is my script: [FindsBy(How = How.Id, Using = "ctl00_MainContent_btnSave")] IWebElement ...
3
votes
2answers
3k views

WebdriverJS ElementNotVisibleError: element not visible

I'm new to Selenium and I think I'm just not understanding what is happening in the code and browser. I can work around my issue by replacing the driver.wait code (posted below) with a driver.sleep(...
0
votes
4answers
10k views

How to right click and select option in WebdriverJS?

I am using Selenium WebdriverJS (NOT Java selenium and NOT Webdriver.io!), which has horrible documentation for beginners. I need to right click an element and move down to "save as", then .sendKeys() ...
2
votes
7answers
8k views

Selenium: how to wait for javascript fadeout (visibility and clickable don't work)

So, in the AUT there's a <div> loading screen covering the entire page, which then fades out and gets replaced in the DOM by the <body>. I'm using ExpectedConditions for visibility and ...
1
vote
1answer
747 views

Cucumber-JS how to modify the information in a failed steps 'Message'

we are using cucumber JS with sync-reqest to do headless end to end testing of our web app. Each scenario has its own x-correlation-id which is set as one of each call's headers - which makes it ...
1
vote
1answer
587 views

Sikuli analog for selenium javascript

I use seleniumjs to automate my tests Is there a tool which can find an element on a page by its image? Or just assert that an image is present somewhere on a page I know Sikuli in Java can do such ...
5
votes
2answers
782 views

Using SuperTest/Protractor on unsecure HTTPS

I am trying to run automated API tests on localhost with an invalid cert. Is there a chromeOption equivalent to "Proceed Anyway" that I can pass to the tests so they can get a response from the url? ...
4
votes
3answers
2k views

Tools for automated testing of web site in JavaFX WebView

Automated testing of web site in JavaFX WebView I have a Web Site, for which I have to write automated tests. The WebSite is built with the following technologies: HTML, CSS, Js, AngularJS. The major ...
2
votes
1answer
734 views

How do I check if a tooltip appears or not?

How do I check if the tooltip appears or not in selenium? When mouseovering the element, I can see the tooltip appear. How do I verify that the tooltip appears? HTML of the Icon: <td class=" text-...
2
votes
1answer
934 views

Protractor Dynamic numer of test runs depened on count() result

In my Protractor Test suite I have some problem with parametrizing number of tests . it('Login and Count', function () { PageObject.login(); var number = element.all(by.something()).count()....
1
vote
3answers
2k views

Nesting callbacks with protractor

I'm using test framework protractor to test an angularjs app. I've been doing this for sometime now and one of the question that I've not been able to answer is : Suppose I want to modify a the value ...
3
votes
3answers
4k views

Can we generate unique distinct users for parallel tests in selenium?

Can we generate unique distinct users for parallel tests in selenium WebDriver and java? Suppose, in google create an account action I want to pass firstname, Lastname, Username & Password for ...
1
vote
1answer
476 views

Anyone find value migrating to NightWatch from Python Selenium API?

My dilemma, I have tons of tests and experience on the Python API to Selenium and webdriver. But, my dev team is big time javascript fans who think everything should be built under node/js. I want to ...
3
votes
2answers
6k views

Switching windows with non angular pages using Webdriver JS

I have a non angular page that I open and then click a link, which changes pages and I fill out a form with some information and then click a button. Upon clicking that button another browser window ...
2
votes
2answers
3k views

How to click on the hidden values in selenium webdriver using java?

I am trying to click on one of the hidden values but it is neither fetching nor it clicking on that value. I am trying for Indian railways berth availability wherein I want the source station value e....
1
vote
4answers
5k views

How can I execute selected test cases from list of testcases in TestNG at runtime?

I want to create a page with the details of test cases (say a HTML Page with some content). Say the testcases will be listed there. When i want to run the test cases then I will select them and click ...
0
votes
1answer
5k views

Unable to click on javascript element through selenium driver

I am using given below xpath but my script is not clicking on these element Login_Btn = "(//a[contains(text(),'Login')])[2]"; OR "//div[@id='bd_login']/a" ; driver.findElement(By.xpath(Login_Btn))...
1
vote
3answers
3k views

How to take the screenshot of a window based GUI application?

I am automating tests of a GUI application similar to calculator. I am using Java and AutoIt for implementing the test cases. I need to take screenshot on failure. I have tried taking screenshot ...
1
vote
0answers
86 views

waitForCondition class change

I'm having an issue with a menu which needs a double click to activate the main option. The first click adds 'focus open' classes to get the ui to open the hover over menu in mobile, the second ...
3
votes
3answers
4k views

Correct CSS selector for selenium

Which css selector's correct for the following HTML code ? <li class="active editing" data-index="0"> <div class="view"> <input class="edit"/> </li> I'm trying to get ...
1
vote
1answer
61 views

How can I move all my seleniumIDE locators to javascript variables (like page objects)?

My locators are all hard-coded into the tests. How can I extract these into variables?
4
votes
4answers
319 views

What tools are recommended for end to end page load time testing (including ajax and styling elements)?

We are looking to measure the length of time it takes for certain key pathways to become 'usable' e.g. certain styling elements will have loaded in and some information ajaxed in on a page. Ideally ...
0
votes
0answers
195 views

search string text in search grid is not working using send keys

I am passing sendKeys( ) through search grid to search a particular string.I am able to click that search text but its not clicking the search string ,Below is the html for that search text: <...
6
votes
7answers
7k views

I want to learn Selenium but not sure about the language I need to learn for automation

Java or Javascript? or maybe another language? Please help me choose the programming language I should learn for Selenium automation and its benefit over other. Any pro's and con's?
3
votes
2answers
1k views

IDE: [error] Threw an exception: missing ; before statement

I keep getting errors with my storeEval script. In IDE the log keeps giving me "[error] Threw an exception: missing ; before statement". I don't know what to do because I have tried putting a similar ...
2
votes
1answer
5k views

Using Protractor Cucumber JS: When running a test, the test passes when it shouldn't

I'm writing a test where I should log in. It passed given the proper inputs but when I change its password/username to garbage, it still passes. I'm new to this and I really think I missed something ...
2
votes
1answer
485 views

Automating Chrome on Windows 8.1 with JavaScript using Selenium's WebDriverJS

I'm automating Chrome on Windows 8.1 with JavaScript using Selenium's WebDriverJS. 1) To get started with WebDriverJS for Node, I downloaded a copy of the ChromeDriver and selenium-server-standalone ...
2
votes
1answer
12k views

How to Handle the File Upload dialog in Protractor for IE11?

I know the default answer to handling explorer.exe is to use AutoIT, but AutoIT utilizes Java Runtime to use the exported .exe to upload the file and close the dialog. My tests are all in Protractor ...
2
votes
3answers
5k views

Stress and Load Testing using Selenium-like tool

I have written some tests in Selenium using NodeJs and I am looking for a way to use those tests for stress testing web apps. Is there any tool that combined with selenium can do the trick? What I am ...
1
vote
2answers
97 views

Windows Phone 8.1 metro JS app testing

I started work as junior QA and after 2 months of manual testing my boss told me to learn about automation. The problem is that I should test app which has been written in JavaScript for Windows ...