Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in DevOps and Agile by (19.7k points)

Where does Selenium WebDriver (a.k.a Selenium 2) get the anonymous profile that it uses when it opens FirefoxDriver? If it used the default for Firefox, %appdata%/roaming/mozilla/firefox/profiles, then if I were to disable a firefox plugin, it should be disabled for Selenium WebDriver also, so why isn't it?

1 Answer

0 votes
by (62.9k points)

While using Firefox in Selenium WebDriver 3.0, it will start a default profile automatically.

But, you can create your own profile and you can name it according to your choice.

Then you can use the below code:

 Profiles profile = new Profiles();

 FirefoxProfile fprofile = profile.getProfile("MyProfile");

 WebDriver driver = new FirefoxDriver(fprofile);

Using this your Firefox Profile will start with a new profile always. You can change the settings according to your choice.

If you are interested to learn Selenium on a much deeper level and want to become a professional in the testing domain, check out Intellipaat’s Selenium online certification exam!

Browse Categories

...