Reputation: 481
I have created a Maven Project for Selenium WebDriver with TestNG. All the dependencies and required plugins are added in POM.xml file.
When I run maven project Maven-test. I'm getting result as below:
> Failed tests: LoginAndVerify.LoginWithInvalidUsernameAndPassword:15 IllegalState The path to the driver exec...
My Test Cases scripts:
import org.testng.annotations.Test;
import java.util.concurrent.TimeUnit;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;
public class LoginAndVerify {
public WebDriver driver;
@Test
public void LoginWithInvalidUsernameAndPassword() {
driver = new ChromeDriver();
driver.get("https://www.google.co.in/");
driver.manage().window().maximize();
System.out.println("URL opened!");
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
}
}
Upvotes: 0
Views: 152