Selenium opens Chrome but won't get past the main page

24 views
Skip to first unread message

Jonathan Clark

unread,
Jun 5, 2018, 10:43:58 PM6/5/18
to Selenium Users
Hi,

I have some code written in JAVA that opens up Chrome and navigates through my companies website for testing purposes. My companies proxy prompts me for authentication after each page, so I enabled an extension (Multipass) that automates authentication. The first problem that I encounter is Chrome opening up the browser without the Multipass extension, so I still get the prompt for authentication which does not allow my Selenium automation to run properly (even though if I were to open Chrome myself, the extension works fine). The second problem that I have is, when I run Selenium using: 

    ChromeOptions options = new ChromeOptions();
    options.addArguments("user-data-dir=C:/Users/#####/AppData/Local/Google/Chrome/User Data");

It never makes it past my home page on Chrome. Meaning when I run my code in Eclipse, Chrome starts but only makes it as far as my companies homepage. BUT if I were to change User Data to another name, e.g:

    ChromeOptions options = new ChromeOptions();
    options.addArguments("user-data-dir=C:/Users/#####/AppData/Local/Google/Chrome/Fake Folder");

It will get past the first page and continue automation (until proxy authentication). Basically, to put it in a nutshell,  whatever folder name I have on the end of my path only runs once. Anything subsequent to the initial run won't make it past the first homepage on Chrome. 

Is there any quick solution to this?

MetaData:
Windows 10
JAVA 10.0.1
Selenium Client & Webdriver Language Bindings 3.12
Chrome Driver 2.39
Chrome 66



Reply all
Reply to author
Forward
0 new messages