Monday, June 10, 2024

Selenium test run without using System.setProperty in the code

 package com.system.pattern;


import org.openqa.selenium.WebDriver;

import org.openqa.selenium.chrome.ChromeDriver;

import org.testng.annotations.BeforeMethod;

import org.testng.annotations.Test;

import io.github.bonigarcia.wdm.WebDriverManager;


public class Practice {


WebDriver driver;


@BeforeMethod

public void setUp() {

WebDriverManager.chromedriver().setup();

driver = new ChromeDriver();

}


@Test(description = "Selenium test run without using System.setProperty in the code")

public void test() {

driver.get("https://suriyaparithy.blogspot.com/");


}

}


Chrome version - 125.0.6422.141


Webdrivermanager version - 5.5.3

No comments:

Post a Comment