Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't set ChromeOptions user-data-dir #939

Closed
bsimpson53 opened this issue Jun 17, 2014 · 4 comments
Closed

Can't set ChromeOptions user-data-dir #939

bsimpson53 opened this issue Jun 17, 2014 · 4 comments

Comments

@bsimpson53
Copy link

I'm trying to set a local user-data-dir (userDataDir) for Chromedriver, in my conf I have:

capabilities: {
    'browserName': 'chrome',
    'ChromeOptions': {
        'args': ['--user-data-dir=/my/path/here']
    }
  }

I'm doing this so that I can set 'protocol_handler.excluded_schemes.localhost': 'false' in "Local State" by hand which I don't seem to be able to set with:

capabilities: {
    'browserName': 'chrome',
    'ChromeOptions': {
        'prefs': { 'protocol_handler.excluded_schemes.localhost': 'false' }
    }
  }

My end goal is to prevent a native chrome alert for an "External Protocol Request" from appearing and derailing my test.

Any alternative approaches gratefully received :)

@elgalu
Copy link
Contributor

elgalu commented Jun 17, 2014

Case might be your issue, try chromeOptions instead of ChromeOptions

@hankduan
Copy link
Contributor

See #175

@juliemr
Copy link
Member

juliemr commented Jun 17, 2014

Yup, that capital C is messing you up.

@juliemr juliemr closed this as completed Jun 17, 2014
@bsimpson53
Copy link
Author

I don't know whether to laugh or cry, thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants