5

I want to use Capybara to run some automated tests with Chrome, how do I choose to run the google-chrome-dev instead of the default Chrome? Only Chrome 78 (unstable) will run, however, Selenium (for Capybara) requires webdriver. Webdriver only support version 77.

I was able to get Chrome running by following these instructions: https://github.com/Microsoft/WSL/issues/648#issuecomment-324562271

WSL Capybara and the WSL Chrome Window:

image

Biswapriyo
  • 11,584
Casey
  • 151

2 Answers2

11

How do I choose to run the google-chrome-dev instead of the default Chrome?

Links:

Choose any one of the following links:

The version and release timeline can be viewed here Chrome Status Schedule.

Steps:

  • Add apt installation key (source):

    wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
    
  • Download the package:

    wget https://dl.google.com/linux/direct/google-chrome-beta_current_amd64.deb
    
  • Try to install the package:

    sudo dpkg -i google-chrome-beta_current_amd64.deb
    
  • Install the dependencies:

    sudo apt -f install
    
  • Now install the actual package:

    sudo dpkg -i google-chrome-beta_current_amd64.deb
    
Biswapriyo
  • 11,584
3

For those who have not yet found the solution (WSL2). Follow this tutorial: chromedriver in WSL2. Many are similar, but what did the trick for me was to place the chromedriver in the corresponding group and user:

sudo chown root:root /usr/bin/chromedriver