Selenium2 firefox: use the default profile

前端 未结 6 1734
挽巷
挽巷 2020-12-05 12:16

Selenium2, by default, starts firefox with a fresh profile. I like that for a default, but for some good reasons (access to my bookmarks, saved passwords, use my add-ons, et

6条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-05 12:44

    I was curious about this as well and what I got to work was very simple. I use the command /Applications/Firefox.app/Contents/MacOS/firefox-bin -P to bring up Profile Manager. After I found which profile I needed to use I used the following code to activate the profile browser = Selenium::WebDriver.for :firefox, :profile => "batman".

    This pulled all of my bookmarks and plug-ins that were associated with that profile.

    Hope this helps.

提交回复
热议问题