Selenium code: Base Class: public class Base { public static WebDriver driver; public Properties pf; public WebDriver initializeDriver() throws IOException, InterruptedException{ pf = new Properties(); System.out.println(1); String workSpacePath = System.getProperty("user.dir"); System.out.println(2); FileInputStream fis = new FileInputStream(workSpacePath +"\\src\\main\\resources\\config\\config.properties"); System.out.println(3); pf.load(fis); System.out.println(4); String browser = pf.getProperty("browser"); //String browser = System.getProperty("browser"); System.out.println(browser); if(browser.equalsIgnoreCase("chrome")) { System.out.println("i am from chrome"); System.setProperty("webdriver.chrome.driver", "C:\\Automation\\Selenium\\drivers\\chromedriver_win32\\chromedriver.exe"); //ChromeOptions options = new ChromeOpti...