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
5
votes
2answers
2k views

Speeding up end-to-end tests

When we execute the same set of end-to-end browser-automated tests on BrowserStack, we notice a dramatic slowdown - tests are much slower than if executed locally and there are occasional failures ...
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?
5
votes
5answers
61k views

Not able to scroll down page using Selenium webdriver [duplicate]

I want to scroll down a page that is coming inside a form, not on the main page. I tried this code: JavascriptExecutor jse = (JavascriptExecutor)driver; jse.executeScript("window.scrollBy(0,250)", "...
3
votes
2answers
5k views

Unable to open Chrome WebDriver in another language

I'd really like to write a Selenium WebDriver test that verifies text is localized. The localization code bases the strings it displays on navigator.language (or navigator.userLanguage for IE). I ...
9
votes
5answers
30k views

WebDriver: Can I inject a jQuery script for a page that isn't using jQuery?

Is it possible to inject a jQuery script into a page if the page isn't already using jQuery? We have a few pages in our sites where we don't add jQuery if it doesn't need it, but I'm using it to ...
32
votes
10answers
14k views

Why should a software QA engineer need to learn JavaScript?

I've seen in lot of job advertisements, companies asking for JavaScript knowledge for QA. So my questions are: What is the use of JavaScript for QA? If JavaScript is used for testing, what kind of ...
10
votes
2answers
577 views

Detecting complicated CSS selectors

This is a follow-up to What makes a good selenium locator? Motivation I've been thinking about detecting the complexity of CSS selectors statically. The scope I'm working in is both test-automation ...
6
votes
2answers
1k views

Switching from JavaScript to TypeScript for Protractor e2e tests

Not very long time ago, Protractor itself migrated to TypeScript internally. I've also heard and seen several Protractor test projects moving to TypeScript. We have a rather big and growing test ...
6
votes
1answer
2k views

Inconsistent results when capturing javascript errors with WebDriver

I'm using a technique I found here, to capture javascript errors for testing purposes. It's a technique that is frequently recommended on Stack Overflow for those who need to catch JavaScript errors ...
3
votes
5answers
549 views

Lightweight load & performance testing frameworks

Which lightweight load and/or performance testing frameworks could you recommend? some considerations: Configuration with not too much coding (some JS would be okay) command line + text editor (...
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 ...
2
votes
1answer
4k views

Wait for element change not present (WebDriver/JavaScript/Jest)

Yesterday I struggled with waiting for a loading indicator to be removed. Added this question and answer here because we spend a lot of time on it and Google didn't help much. Hopefully this will help ...
2
votes
1answer
6k views

Selenium IDE Store variable in Javascript of Page

I am attempting to inject Javascript directly into a page in order to set a variable for the page. I am still rather new to the IDE and I have seen the runScript function and I think it does what I ...
1
vote
0answers
1k views

Handling Alert box on page load [closed]

Is there any way to identify the JavaScript alert box (on page load) in selenium IDE? I used commands like "storAlert", "assertAlert" etc. But selenium not identifying alert box.
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
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 ...