Install browser preferences after downloading and unpacking firefox instances. Based on:   https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Enterprise_deployment_before_60#Configuration
497773
async function installFirefoxPreferences(executablePath) {
  const firefoxFolder = path.dirname(executablePath);
  const {helper} = require('../lib/helper');
  const mkdirAsync = helper.promisify(fs.mkdir.bind(fs));

  let prefPath = '';
  let configPath = '';
  if (os.platform() === 'darwin') {
    prefPath = path.join(firefoxFolder, '..', 'Resources', 'defaults', 'pref');
    configPath = path.join(firefoxFolder, '..', 'Resources');
  } else if (os.platform() === 'linux') {
    if (!fs.existsSync(path.join(firefoxFolder, 'browser', 'defaults')))
      await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults'));
    if (!fs.existsSync(path.join(firefoxFolder, 'browser', 'defaults', 'preferences')))
      await mkdirAsync(path.join(firefoxFolder, 'browser', 'defaults', 'preferences'));
    prefPath = path.join(firefoxFolder, 'browser', 'defaults', 'preferences');
    configPath = firefoxFolder;
  } else if (os.platform() === 'win32') {
    prefPath = path.join(firefoxFolder, 'defaults', 'pref');
    configPath = firefoxFolder;
  } else {
    throw new Error('Unsupported platform: ' + os.platform());
  }

  await Promise.all([
    copyFile({
      from: path.join(__dirname, '00-puppeteer-prefs.js'),
      to: path.join(prefPath, '00-puppeteer-prefs.js'),
    }),
    copyFile({
      from: path.join(__dirname, 'puppeteer.cfg'),
      to: path.join(configPath, 'puppeteer.cfg'),
    }),
  ]);
}
187732
def from_settings(cls):
        """"""
        from cloud_browser.app_settings import settings
        from django.core.exceptions import ImproperlyConfigured

        conn_cls = conn_fn = None
        datastore = settings.CLOUD_BROWSER_DATASTORE
        if datastore == 'AWS':
            # Try AWS
            from cloud_browser.cloud.aws import AwsConnection
            account = settings.CLOUD_BROWSER_AWS_ACCOUNT
            secret_key = settings.CLOUD_BROWSER_AWS_SECRET_KEY
            if account and secret_key:
                conn_cls = AwsConnection
                conn_fn = lambda: AwsConnection(account, secret_key)

        if datastore == 'Google':
            # Try Google Storage
            from cloud_browser.cloud.google import GsConnection
            account = settings.CLOUD_BROWSER_GS_ACCOUNT
            secret_key = settings.CLOUD_BROWSER_GS_SECRET_KEY
            if account and secret_key:
                conn_cls = GsConnection
                conn_fn = lambda: GsConnection(account, secret_key)

        elif datastore == 'Rackspace':
            # Try Rackspace
            account = settings.CLOUD_BROWSER_RACKSPACE_ACCOUNT
            secret_key = settings.CLOUD_BROWSER_RACKSPACE_SECRET_KEY
            servicenet = settings.CLOUD_BROWSER_RACKSPACE_SERVICENET
            authurl = settings.CLOUD_BROWSER_RACKSPACE_AUTHURL
            if account and secret_key:
                from cloud_browser.cloud.rackspace import RackspaceConnection
                conn_cls = RackspaceConnection
                conn_fn = lambda: RackspaceConnection(
                    account,
                    secret_key,
                    servicenet=servicenet,
                    authurl=authurl)

        elif datastore == 'Filesystem':
            # Mock filesystem
            root = settings.CLOUD_BROWSER_FILESYSTEM_ROOT
            if root is not None:
                from cloud_browser.cloud.fs import FilesystemConnection
                conn_cls = FilesystemConnection
                conn_fn = lambda: FilesystemConnection(root)

        if conn_cls is None:
            raise ImproperlyConfigured(
                "No suitable credentials found for datastore: %s." %
                datastore)

        # Adjust connection function.
        conn_fn = staticmethod(conn_fn)

        # Directly cache attributes.
        cls.__connection_cls = conn_cls
        cls.__connection_fn = conn_fn

        return conn_cls, conn_fn
869445
function buildFirefox(destDir) {
  if (!destDir) {
    throw new Error('No destination directory. Either set $FIREFOX_HOME or use --location ...');
  }
  var log = 'Building Firefox outputs to ' + (destDir || 'built/ff') + '.\n\n';

  if (!destDir) {
    copy.mkdirSync(path.dirname(require.main.filename) + '/built/ff', 493 /*0755*/);
  }

  var testDir = '/browser/devtools/commandline/test';
  var propsDir = '/browser/locales/en-US/chrome/browser/devtools';

  if (destDir) {
    if (!fs.existsSync(destDir + testDir)) {
      throw new Error('Missing path for tests: ' + destDir + testDir);
    }
    if (!fs.existsSync(destDir + propsDir)) {
      throw new Error('Missing path for l10n string: ' + destDir + propsDir);
    }
  }

  // Convert GCLI test files to Mochitest files. The excluded tests are those
  // that rely on commands that ship with GCLI-web but are not implemented in
  // the same way in Firefox, and require which has been manually translated
  copy({
    source: {
      root: 'lib/gcli/test/',
      include: /test.*\.js$/,
      exclude: [
        /testHelp\.js$/,
        /testPref\.js$/,
        /testSettings\.js$/,
        /testRequire\.js$/
      ]
    },
    filter: createCommonJsToJsTestFilter(),
    filenameFilter: function(filename) {
      // the t prefix prevents 'test' from matching the directory name
      return filename.replace(/t\/test/, 't\/browser_gcli_').toLowerCase();
    },
    dest: (destDir ? destDir + testDir : 'built/ff')
  });
  copy({
    source: 'lib/gcli/test/mockCommands.js',
    filter: commonJsToJsMockFilter,
    dest: (destDir ? destDir + testDir : 'built/ff') + '/mockCommands.js'
  });
  copy({
    source: 'lib/gcli/test/mockFileCommands.js',
    filter: commonJsToJsMockFilter,
    dest: (destDir ? destDir + testDir : 'built/ff') + '/mockFileCommands.js'
  });

  // Package the i18n strings
  copy({
    source: [ 'lib/gcli/nls/strings.js' ],
    filter: tweakI18nStrings,
    dest: (destDir ? destDir + propsDir : 'built/ff') + '/gcli.properties'
  });

  return log;
}
847386
def _download_initial_config(self):
        """"""
        _initial_config = self._download_running_config()  # this is a bit slow!
        self._last_working_config = _initial_config
        self._config_history.append(_initial_config)
        self._config_history.append(_initial_config)
800452
function buildSettings() {
  var pf32Path = process.env['ProgramFiles(x86)'],
      pf64Path = process.env.ProgramFiles,
      settings,
      tfPath = '/Common7/IDE/TF.exe';

  switch (true) {
    case fileExists(pf32Path + '/Microsoft Visual Studio/2017/Enterprise', true):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio/2017/Enterprise/Common7/IDE/CommonExtensions/Microsoft/TeamFoundation/Team Explorer/TF.exe',
        vsArchitecture: 32,
        vsVersion: 2017
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio/2017/Professional', true):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio/2017/Professional/Common7/IDE/CommonExtensions/Microsoft/TeamFoundation/Team Explorer/TF.exe',
        vsArchitecture: 32,
        vsVersion: 2017
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio/2017/Community', true):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio/2017/Community/Common7/IDE/CommonExtensions/Microsoft/TeamFoundation/Team Explorer/TF.exe',
        vsArchitecture: 32,
        vsVersion: 2017
      };
      break;

    case fileExists(pf64Path + '/Microsoft Visual Studio 14.0' + tfPath):
      settings = {
        tfPath: pf64Path + '/Microsoft Visual Studio 14.0' + tfPath,
        vsArchitecture: 64,
        vsVersion: 2015
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio 14.0' + tfPath):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio 14.0' + tfPath,
        vsArchitecture: 32,
        vsVersion: 2015
      };
      break;

    case fileExists(pf64Path + '/Microsoft Visual Studio 12.0' + tfPath):
      settings = {
        tfPath: pf64Path + '/Microsoft Visual Studio 12.0' + tfPath,
        vsArchitecture: 64,
        vsVersion: 2013
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio 12.0' + tfPath):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio 12.0' + tfPath,
        vsArchitecture: 32,
        vsVersion: 2013
      };
      break;

    case fileExists(pf64Path + '/Microsoft Visual Studio 11.0' + tfPath):
      settings = {
        tfPath: pf64Path + '/Microsoft Visual Studio 11.0' + tfPath,
        vsArchitecture: 64,
        vsVersion: 2012
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio 11.0' + tfPath):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio 11.0' + tfPath,
        vsArchitecture: 32,
        vsVersion: 2012
      };
      break;

    case fileExists(pf64Path + '/Microsoft Visual Studio 10.0' + tfPath):
      settings = {
        tfPath: pf64Path + '/Microsoft Visual Studio 10.0' + tfPath,
        vsArchitecture: 64,
        vsVersion: 2010
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio 10.0' + tfPath):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio 10.0' + tfPath,
        vsArchitecture: 32,
        vsVersion: 2010
      };
      break;

    case fileExists(pf64Path + '/Microsoft Visual Studio 9.0' + tfPath):
      settings = {
        tfPath: pf64Path + '/Microsoft Visual Studio 9.0' + tfPath,
        vsArchitecture: 64,
        vsVersion: 2008
      };
      break;

    case fileExists(pf32Path + '/Microsoft Visual Studio 9.0' + tfPath):
      settings = {
        tfPath: pf32Path + '/Microsoft Visual Studio 9.0' + tfPath,
        vsArchitecture: 32,
        vsVersion: 2008
      };
      break;

    case fileExists(__dirname + '/../test/.mock'):
      settings = {};
      break;

    default:
      output.error('Impossible to find you TF.exe');
      break;
  }

  output.info('Writing ' + settingsPath);

  var fileSource = JSON.stringify(settings, null, 2);
  fs.writeFileSync(settingsPath, fileSource, 'utf8');
}
584004
def install(config):  # pragma: no cover
        """"""
        client = Client()
        client.prepare_connection()
        key_api = API(client)
        key_api.install()
134631
public void configureDefaults() throws Exception
    {
        //cannot configure if the context is already started
        if (_context.isStarted())
        {
            if (log.isDebugEnabled()){log.debug("Cannot configure webapp after it is started");};
            return;
        }
        
        getWebApplicationContext().setWelcomeFiles(null);
        
        String defaultsDescriptor=getWebApplicationContext().getDefaultsDescriptor();
        if(defaultsDescriptor!=null&&defaultsDescriptor.length()>0)
        {
            Resource dftResource=Resource.newSystemResource(defaultsDescriptor);
            if(dftResource==null)
                dftResource=Resource.newResource(defaultsDescriptor);
            XmlParser.Node defaultConfig=xmlParser.parse(dftResource.getURL());
            initialize(defaultConfig);
        }
    }
416786
def edit_preferences(self):
        """"""
        from spyder.preferences.configdialog import ConfigDialog
        dlg = ConfigDialog(self)
        dlg.size_change.connect(self.set_prefs_size)
        if self.prefs_dialog_size is not None:
            dlg.resize(self.prefs_dialog_size)
        for PrefPageClass in self.general_prefs:
            widget = PrefPageClass(dlg, main=self)
            widget.initialize()
            dlg.add_page(widget)
        for plugin in [self.workingdirectory, self.editor,
                       self.projects, self.ipyconsole,
                       self.historylog, self.help, self.variableexplorer,
                       self.onlinehelp, self.explorer, self.findinfiles
                       ]+self.thirdparty_plugins:
            if plugin is not None:
                try:
                    widget = plugin.create_configwidget(dlg)
                    if widget is not None:
                        dlg.add_page(widget)
                except Exception:
                    traceback.print_exc(file=sys.stderr)
        if self.prefs_index is not None:
            dlg.set_current_index(self.prefs_index)
        dlg.show()
        dlg.check_all_settings()
        dlg.pages_widget.currentChanged.connect(self.__preference_page_changed)
        dlg.exec_()
932020
public function _initialize() {
		$this->wd_host = sprintf( 'http://%s:%s@hub.browserstack.com/wd/hub', $this->config['username'], $this->config['access_key'] );

		$this->capabilities = $this->config['capabilities'];
		$this->capabilities[ \WebDriverCapabilityType::BROWSER_NAME ] = $this->config['browser'];
		if ( ! empty( $this->config['version'] ) ) {
			$this->capabilities[ \WebDriverCapabilityType::VERSION ] = $this->config['version'];
		}

		$this->webDriver = \RemoteWebDriver::create( $this->wd_host, $this->capabilities );
		$this->webDriver->manage()->timeouts()->implicitlyWait( $this->config['wait'] );

		$this->initialWindowSize();
	}
1287459
@Before
	public final void setUp() {
		fileUtil = new FileUtils();
		xmlUtils = new XMLUtils(fileUtil);
		httpUtils = new HttpCallUtils(fileUtil);

		fileUtil.loadPropertiesBundle("selenium");

		String browserName = fileUtil
				.getPropertyAsString("selenium", "browser");
		String browserVersion = fileUtil.getPropertyAsString("selenium",
				"browserVersion");
		String runMode = fileUtil.getPropertyAsString("selenium", "runMode");
		String proxyHost = fileUtil
				.getPropertyAsString("selenium", "proxyHost");
		String proxyPort = fileUtil
				.getPropertyAsString("selenium", "proxyPort");
		String gridUrl = fileUtil.getPropertyAsString("selenium", "gridUrl");
		String platform = fileUtil.getPropertyAsString("selenium", "platform");
		String userAgent = fileUtil
				.getPropertyAsString("selenium", "userAgent");
		String noProxyFor = fileUtil.getPropertyAsString("selenium",
				"noProxyFor");
		String screenShotFolder = fileUtil.getPropertyAsString("selenium",
				"screenshotFolder");

		boolean assumeAllCertsUntrusted = fileUtil.getPropertyAsBoolean(
				"selenium", "assumeAllCertsUntrusted");
		String jsEnabled = fileUtil
				.getPropertyAsString("selenium", "jsEnabled");
		boolean flakiness = fileUtil.getPropertyAsBoolean("selenium",
				"flakiness");
		boolean acceptAllCerts = fileUtil.getPropertyAsBoolean("selenium",
				"acceptAllCerts");
		String profileLocation = fileUtil.getPropertyAsString("selenium",
				"browserProfile");
		String takeScreenshots = fileUtil.getPropertyAsString("selenium",
				"takeScreenshots");

		boolean jsEnabledBoolean = Boolean.getBoolean(jsEnabled);
		boolean takeScreenshotsBoolean = Boolean.getBoolean(takeScreenshots);

		/**
		 * assign default values if these are null
		 */
		if (isPropertyNotSet(profileLocation)) {
			profileLocation = null;
		}
		if (isPropertyNotSet(userAgent)) {
			userAgent = null;
		}

		if (isPropertyNotSet(screenShotFolder)) {
			screenShotFolder = Constants.DEFAULT_SCREENSHOT_FOLDER;
		}

		if (isPropertyNotSet(noProxyFor)) {
			noProxyFor = null;
		}

		if (isPropertyNotSet(browserVersion)) {
			browserVersion = null;
		}

		if (isPropertyNotSet(browserName)) {
			browserName = Constants.Browsers.HTML_UNIT;
		}

		if (isPropertyNotSet(runMode)) {
			runMode = Constants.RunMode.NORMAL;
		}

		if (isPropertyNotSet(platform)) {
			platform = Constants.Platform.WINDOWS;
		}

		if (isPropertyNotSet(proxyHost)) {
			proxyHost = null;
		}

		if (isPropertyNotSet(proxyPort)) {
			proxyPort = null;
		}

		if (isPropertyNotSet(jsEnabled)) {
			jsEnabledBoolean = true;
		}

		if (isPropertyNotSet(takeScreenshots)) {
			takeScreenshotsBoolean = true;
		}

		screen.setTakeScreenshot(takeScreenshotsBoolean);
		screen.setScreenshotFolder(new File(screenShotFolder));

		WebDriverHelper.Builder driverBuilder = new WebDriverHelper.Builder();
		driver = driverBuilder.browser(browserName).runMode(runMode)
				.proxy(proxyHost, proxyPort, noProxyFor)
				.acceptAllCerts(acceptAllCerts).grid(gridUrl)
				.platform(platform).flackinessForIe(flakiness)
				.profileLocation(profileLocation).userAgent(userAgent)
				.jsEnabled(jsEnabledBoolean).browserVersion(browserVersion)
				.assumeAllCertsUtrusted(assumeAllCertsUntrusted).buildDriver();

		LOG.info("Driver returned: " + driver);

		helper = new WebDriverHelper(driver);
		screen.setDriver(driver);

		this.doAdditionalSetUp();
	}
1310198
function setOptions(config) {
    // We expect config at `config.plugins.fbFlo`.
    var cfg = config && config.plugins && config.plugins.fbFlo || {};

    this.config = defaults(pick(cfg, OPTIONS), FbFloBrunch.DEFAULTS);

    // We're using the configuration's public path, or its Brunch default,
    // to know what directory fb-flo should watch.
    this.config.publicPath = config && config.paths && config.paths.public ||
      path.join(process.cwd(), 'public');

    // Allow for basic, fb-flo supported true/false values for the resolver's
    // `reload` setting, but also allow anymatch sets (way more flexible).
    if (this.config.resolverReload) {
      if (true === this.config.resolverReload) {
        this.config.resolverReload = function alwaysReload() { return true; };
      } else {
        this.config.resolverReload = anymatch(this.config.resolverReload);
      }
    }

    // If a client-side message is defined, build the `update` resolver method.
    if (this.config.message) {
      var msg = this.config.message.toString().replace(/"/g, '\\"');
      var suffix = ['_resourceURL'];
      // We allow custom colors for the resource name and overall text
      // (this currently only works in Chrome DevTools; but so does fb-flo…).
      // Any valid CSS color syntax is usable.
      if (this.config.messageResourceColor) {
        msg = msg.replace('%s', '%c%s%c');
        suffix.unshift('"color: ' + this.config.messageResourceColor + '"');
        suffix.push('"color: ' + (this.config.messageColor || 'black') + '"');
      }
      if (this.config.messageColor) {
        msg = '%c' + msg;
        suffix.unshift('"color: ' + this.config.messageColor + '"');
      }
      suffix = suffix.join(', ');
      var level = this.config.messageLevel;
      var code = 'console.' + level + '("' + msg + '", ' + suffix + ');';
      // Closures won't marshal over to the browser, hence the autonomous
      // function code generation.
      /* jshint evil:true */
      this.update = new Function('_window', '_resourceURL', code);
    }
  }
589138
function preferencesReload() {
          return this.initializedPromise.then(function () {
            this._readFromStorage(this.defaults).then(function (prefObj) {
              if (prefObj) {
                this.prefs = prefObj;
              }
            }.bind(this));
          }.bind(this));
        }
1286911
protected void installDefaults() {
        updateStyle(splitPane);

        setOrientation(splitPane.getOrientation());
        setContinuousLayout(splitPane.isContinuousLayout());

        resetLayoutManager();

        /*
         * Install the nonContinuousLayoutDivider here to avoid having to
         * add/remove everything later.
         */
        if (nonContinuousLayoutDivider == null) {
            setNonContinuousLayoutDivider(createDefaultNonContinuousLayoutDivider(), true);
        } else {
            setNonContinuousLayoutDivider(nonContinuousLayoutDivider, true);
        }

        // focus forward traversal key
        if (managingFocusForwardTraversalKeys == null) {
            managingFocusForwardTraversalKeys = new HashSet();
            managingFocusForwardTraversalKeys.add(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0));
        }
        splitPane.setFocusTraversalKeys(KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS, managingFocusForwardTraversalKeys);
        // focus backward traversal key
        if (managingFocusBackwardTraversalKeys == null) {
            managingFocusBackwardTraversalKeys = new HashSet();
            managingFocusBackwardTraversalKeys.add(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.SHIFT_MASK));
        }
        splitPane.setFocusTraversalKeys(KeyboardFocusManager.BACKWARD_TRAVERSAL_KEYS, managingFocusBackwardTraversalKeys);
    }
142675
def setup_profile(self, firebug=True, netexport=True):
        
        profile = webdriver.FirefoxProfile()
        profile.set_preference("app.update.enabled", False)
        if firebug:
            profile.add_extension(os.path.join(self.cur_path, 'extensions/firebug-2.0.8.xpi'))
            profile.set_preference("extensions.firebug.currentVersion", "2.0.8")
            profile.set_preference("extensions.firebug.allPagesActivation", "on")
            profile.set_preference("extensions.firebug.defaultPanelName", "net")
            profile.set_preference("extensions.firebug.net.enableSites", True)
            profile.set_preference("extensions.firebug.delayLoad", False)
            profile.set_preference("extensions.firebug.onByDefault", True)
            profile.set_preference("extensions.firebug.showFirstRunPage", False)
            profile.set_preference("extensions.firebug.net.defaultPersist", True)  # persist all redirection responses
        if netexport:
            har_path = os.path.join(self.cur_path, "har")
            if not os.path.exists(har_path):
                os.mkdir(har_path)
            profile.add_extension(os.path.join(self.cur_path, 'extensions/netExport-0.9b7.xpi'))
            profile.set_preference("extensions.firebug.DBG_NETEXPORT", True)
            profile.set_preference("extensions.firebug.netexport.alwaysEnableAutoExport", True)
            profile.set_preference("extensions.firebug.netexport.defaultLogDir", har_path)
            profile.set_preference("extensions.firebug.netexport.includeResponseBodies", True)
        return profile
1269176
private void setChromeOptions(final DesiredCapabilities capabilities, ChromeOptions chromeOptions) {

        // Set custom downloaded file path. When you check content of downloaded file by robot.
        final HashMap<String, Object> chromePrefs = new HashMap<>();
        chromePrefs.put("download.default_directory", System.getProperty(USER_DIR) + File.separator + DOWNLOADED_FILES_FOLDER);
        chromeOptions.setExperimentalOption("prefs", chromePrefs);

        // Set custom chromium (if you not use default chromium on your target device)
        final String targetBrowserBinaryPath = Context.getWebdriversProperties("targetBrowserBinaryPath");
        if (targetBrowserBinaryPath != null && !"".equals(targetBrowserBinaryPath)) {
            chromeOptions.setBinary(targetBrowserBinaryPath);
        }

        capabilities.setCapability(ChromeOptions.CAPABILITY, chromeOptions);
    }
332304
function setConfig(defaultConfig, server) {
    if (server === 'ne') {
        defaultConfig.captureTimeout = 100000;

        defaultConfig.customLaunchers = {
            'IE8': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'internet explorer',
                version: '8'
            },
            'IE9': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'internet explorer',
                version: '9'
            },
            'IE10': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'internet explorer',
                version: '10'
            },
            'IE11': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'internet explorer',
                version: '11'
            },
            'Edge': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'MicrosoftEdge'
            },
            'Chrome-WebDriver': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'chrome'
            },
            'Firefox-WebDriver': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'firefox'
            },
            'Safari-WebDriver': {
                base: 'WebDriver',
                config: webdriverConfig,
                browserName: 'safari'
            }
        };

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        defaultConfig.browsers = [
            'IE8',
            'IE9',
            'IE10',
            'IE11',
            'Edge',
            'Chrome-WebDriver',
            'Firefox-WebDriver'
            // 'Safari-WebDriver' // active only when safari test is needed
        ];

        defaultConfig.webpack.module.preLoaders = [{
            test: /\.js$/,
            include: path.resolve('./src/js'),
            loader: 'istanbul-instrumenter'
        }];

        // test results reporter to use
        // possible values: 'dots', 'progress'
        // available reporters: https://npmjs.org/browse/keyword/karma-reporter
        defaultConfig.reporters = [
            'dots',
            'coverage',
            'junit'
        ];

        // optionally, configure the reporter
        defaultConfig.coverageReporter = {
            dir: 'report/coverage/',
            reporters: [
                {
                    type: 'html',
                    subdir: function(browser) {
                        return 'report-html/' + browser;
                    }
                },
                {
                    type: 'cobertura',
                    subdir: function(browser) {
                        return 'report-cobertura/' + browser;
                    },
                    file: 'cobertura.txt'
                }
            ]
        };

        defaultConfig.junitReporter = {
            outputDir: 'report/junit',
            suite: ''
        };
    } else {
        defaultConfig.captureTimeout = 60000;

        defaultConfig.reporters = [
            'karmaSimpleReporter'
        ];

        defaultConfig.specReporter = {
            suppressPassed: true,
            suppressSkipped: true,
            suppressErrorSummary: true
        };

        // start these browsers
        // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
        defaultConfig.browsers = [
            'ChromeHeadless'
        ];
    }
}
34435
public void initializeDefaultPreferences() {
		IPreferenceStore store = Activator.getDefault().getPreferenceStore();
		store.setDefault(PreferenceConstants.P_DEFAULT_ROOT_FOLDER, PreferencesUtil.getDefaultRootFolder());
		store.setDefault(PreferenceConstants.P_MAVEN_HOME, PreferencesUtil.getMavenHome());
		store.setDefault(PreferenceConstants.P_GROOVY_MODEL, PreferencesUtil.getCustomGroovyModelImpl());
		store.setDefault(PreferenceConstants.P_ECLIPSE_GOAL, "eclipse:eclipse");
		store.setDefault(PreferenceConstants.P_SFTP_ROOT_FOLDER, PreferencesUtil.getDefaultSftpRootFolder());
		
/*
    static public String getDefaultRootFolder() {
    static public String getMavenHome() {
	static public String getCustomGroovyModelImpl() {
    static public String getDefaultSftpRootFolder() {
 */
	}