Desired Capabilities for Firefox/Firefox (headless)

Estimated reading time: 1 minute

You can locate Firefox settings file at this path: **_\\settings\\internal\\com.kms.katalon.core.webui.firefox.properties._**

You can access the useful Desired Capabilities for Firefox through:

  1. Open Firefox browser
  2. On the address bar type in ‘about:config’
  3. Search for ‘browser’ keys
  4. Create a key called ‘firefox_profile’ in Katalon Studio settings and add your settings there.

Some common Desired Capabilities:

  1. Start Firefox at default page: browser.startup.homepage

    {"FIREFOX_DRIVER":{"firefox_profile":{"browser.startup.homepage":"www.google.com"}}}
    

  2.  Never ask for file download for file MIME type mentioned. The list of MIME type can be found here.

{"FIREFOX_DRIVER":{"firefox_profile":{"browser.download.folderList":"2","browser.helperApps.alwaysAsk.force":false,"browser.download.manager.showWhenStarting":false,"browser.download.dir":"C:\\Downloads","browser.download.downloadDir":"C:\\Downloads","browser.download.defaultFolder":"C:\\Downloads","browser.helperApps.neverAsk.saveToDisk":"text/html"}}}

Code sample can be found in this project: https://github.com/katalon-studio-samples/tips-and-tricks