Explain me how to execute JavaScript in Selenium?
Submitted by: MuhammadJavaScriptExecuter is used for JavaScript execution in Selenium.
A simple example:
WebDriver driver = new FireFoxDriver();
if (driver instanceof JavascriptExecutor) {
((JavascriptExecutor)driver).executeScript("{JavaScript Code}");
}
Submitted by: Muhammad
A simple example:
WebDriver driver = new FireFoxDriver();
if (driver instanceof JavascriptExecutor) {
((JavascriptExecutor)driver).executeScript("{JavaScript Code}");
}
Submitted by: Muhammad
Read Online Automation Job Interview Questions And Answers
Top Automation Questions
☺ | What is Selenium? |
☺ | Tell me does the Selenium have any limitations? |
☺ | Tell me what is an Absolute XPath? |
☺ | Explain me what the WebDriver supported Mobile Testing Drivers do you know? |
☺ | Tell us what is the alternate way to click on login button? |
Top Testing Categories
☺ | Manual Testing Interview Questions. |
☺ | Rational TestSuite Interview Questions. |
☺ | QTP Interview Questions. |
☺ | Database Testing Interview Questions. |
☺ | Software QA Interview Questions. |