-1

i'm trying to run selendroid web for practice but i'm getting errors even i update selenium version (2.48.2) and set all paths correctly.

below is my code and i'm getting this error.

Please help me...

NoSuchMethodError: org.openqa.selenium.remote.CommandInfo.(Ljava/lang/String;Lorg/openqa/selenium/remote/HttpVerb;)V

 package com.guru.test;

 import io.selendroid.SelendroidCapabilities;
  import io.selendroid.SelendroidDriver;

  import org.openqa.selenium.By;
  import org.openqa.selenium.WebDriver;
 import org.openqa.selenium.WebElement;
import org.openqa.selenium.remote.DesiredCapabilities;
 import org.testng.annotations.AfterSuite;
 import org.testng.annotations.BeforeSuite;
  import org.testng.annotations.Test;

public class testWeb {

public WebDriver driver;

@BeforeSuite
public void setUp() throws Exception
{
    DesiredCapabilities caps = SelendroidCapabilities.android();        
    driver = new SelendroidDriver(caps);
}

@Test
public void WebSiteTest() throws Exception
{
    driver.get("http://google.com");
    WebElement searchQuery = driver.findElement(By.name("q"));
    searchQuery.click();
    searchQuery.sendKeys("Test");
    WebElement submit = driver.findElement(By.name("btnG"));
    submit.click();
}

@AfterSuite
public void tearDown() throws Exception{
    driver.quit();
}

 }

1 Answers1

0

I think you have mixed up selenium and selendroid jars. selendroid-standalone + selendroid-client should be enough for this.

Bhushan
  • 1,489
  • 3
  • 27
  • 45