Use Selenium with Chromium Browser

前端 未结 6 1322
不知归路
不知归路 2020-12-05 10:50

In the Selenium options (on Firefox) I can find Custom browser.

Is it possible to use this option to run a Selenium test in Chromiu

6条回答
  •  暖寄归人
    2020-12-05 11:31

    Yes. For Chromium use:

    DefaultSelenium selenium = new DefaultSelenium("localhost", 4444, "*custom path/to/chromium" , "www.google.com");
    selenium.start();
    

    The other options that you can use are *custom, *chrome(note: this is not Google chrome, its a firefox mode only), *googlechrome, *iexplore. Please check selenium documentation for complete list of the modes.

    EDIT: Changed googlechrome to chromium

提交回复
热议问题