Open a Firefox profile, start a web page in the browser.
I have this code that works for me to open firefox and go to the page but it does not do it in the specific profile. Could you please give me a help, I have exhausted all the tutorials. thanks
import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.openqa.selenium.remote.DesiredCapabilities;
public class MM {
public static void main(String[] args) {
System.setProperty("webdriver.gecko.driver","C:\Users\MM\Desktop\fbc\lib\geckodriver.exe");
DesiredCapabilities capabilities = DesiredCapabilities.firefox();
capabilities.setCapability("marionette",true);
try{
WebDriver driver = new FirefoxDriver();
driver.get("https://google.com");
Thread.sleep(1800);
}catch(Exception e){
System.out.println(e);
}
}
}