swd-recorder
swd-recorder copied to clipboard
Binary file path for any browser (or customized path)
Hello,
It's just my thought and i have implemented same thing in the page recorder to locate customized path of the browser.
-
i have added two controls (1.check box and edit filed) when user selects browser to start, if selects check box and entering the binary path then tool will tries to identifying the customized path other wise it will take default installation location.
-
Added few line of code in webdriverUtils.cs under "StartEmbededWebDriver" method private static IWebDriver StartEmbededWebDriver(WebDriverOptions browserOptions) { switch (browserOptions.BrowserName) {
case WebDriverOptions.browser_Firefox:
if (browserOptions.BinaryURL != "" && browserOptions.IsBinary) {
FirefoxBinary ffBinary = new FirefoxBinary(browserOptions.BinaryURL); FirefoxProfile firefoxProfile = new FirefoxProfile(); return new FirefoxDriver(ffBinary, firefoxProfile); }else { return new FirefoxDriver(); }
Note: i hope we can use same logic for other browsers as well.
- i have added the below 2 controls as,
if i am not correct ,please excuse me and tune for better solution.
Hi Ravi,
Thank you for sharing your ideas. In the future release, there will be a way to specify the Firefox binary path using the configuration profiles. The users will be enabled to configure additional browser capabilities and create multiple profiles even for same browser type, but with different settings. The firefox binary path will be one among those settings. Unfortunately every "local" WebDriver's browser type uses its own way to configure the instance and I need to implement this for each browser (FF, Chrome, IE, PahntomJS, Edge) so I am not sure when the next release will happen.
I thank you for sharing your experience and ideas!
- Dmytro
Thank you , dzharii.
Hello,
Any update on the progress for this?
Thanks