Java Script errors with Firefox Driver

I am trying to run some of the exercises. When I run the FindElement Practice 1 (http://toolsqa.com/selenium-webdriver/findelement-and-findelements-command/), I get the following error message:

JavaScript error: http://toolsqa.com/wp-content/themes/dt-the7/js/above-the-fold.min.js?ver=3.8.1, line 1: TypeError: jQuery.browser is undefined

JavaScript error: http://toolsqa.com/wp-content/themes/dt-the7/js/main.min.js?ver=3.8.1, line 7: TypeError: t.browser is undefined

Is this due to a mistake on my end (if so, then what), or is it due to issues with the Firefox driver?

My full code is:

package automationFramework;

 

import org.openqa.selenium.By;

 

import org.openqa.selenium.WebDriver;

 

import org.openqa.selenium.WebElement;

 

import org.openqa.selenium.firefox.FirefoxDriver;

 

 

public class PracticeElement2 {

 

public static void main(String[] args) throws InterruptedException {

 

System.setProperty(“webdriver.gecko.driver”, “C:\\Users\\jakobrjensen\\Documents\\Værktøjer\\Selenium\\geckodriver.exe”);

 

//Create a new instance of the Firefox driver

 

WebDriver driver = new FirefoxDriver();

 

//Launch the Online Store Website

 

driver.get(“http://toolsqa.wpengine.com/automation-practice-form/”);

 

//Partial Link Test

 

driver.findElement(By.partialLinkText(“Partial”)).click();;

 

//Identify Button by tagname

 

WebElement element = driver.findElement(By.tagName(“Button”));

 

//Converting element to string

 

String elementString = element.toString();

 

//Printout elementString

 

System.out.println(elementString);

 

//Click on Link Test”

 

driver.findElement(By.linkText(“Link Test”)).click();

 

//Wait for 5 seconds

 

Thread.sleep(5);

 

//Close the driver

 

driver.quit();

 

}

}

JakobJensen Default Asked on November 1, 2016 in Selenium WebDriver.
Add Comment
0 Answer(s)

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.