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

Stop using webdrivers gem #43

Merged
merged 2 commits into from
Mar 7, 2022
Merged

Stop using webdrivers gem #43

merged 2 commits into from
Mar 7, 2022

Commits on Mar 7, 2022

  1. Stop using webdrivers gem

    We've traditionally used the gem [`webdrivers`][webdrivers] to automagically install ChromeDriver on the system at runtime, so that it's available for use by Capybara and headless Jasmine tests.
    
    However this approach is beginning to cause us some problems because Google Chrome and ChromeDriver aren't currently available as Linux ARM binaries. This means that developers on Apple M1 MacBooks are unable to run tests when working in the [govuk-docker] development environment.
    
    We've therefore made the decision to change how we install and use Chrome and its associated WebDriver. Instead of applications being responsible for installing ChromeDriver via this gem's use of `webdrivers`, we've made it the responsibility of the underlying operating system to provide a compatible browser and WebDriver.
    
    In everyday use, this change should be unnoticeable because we've prepared our tooling ahead of time:
    - govuk-docker now comes with ChromeDriver (see alphagov/govuk-docker#577)
    - Jasmine CI workers also have ChromeDriver (see alphagov/govuk-puppet#11568)
    - The GitHub Actions `ubuntu-latest` image has ChromeDriver pre-installed (see [the docs][ubuntu-latest])
    
    However, if you're running tests in another environment (e.g. local development on bare metal), you'll need to make sure ChromeDriver is available. This is usually as simple as running:
    
    ```
    $ brew install chromedriver
    ```
    
    [webdrivers]: https://rubygems.org/gems/webdrivers
    [govuk-docker]: https://github.com/alphagov/govuk-docker
    [ubuntu-latest]: https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu2004-Readme.md#browsers-and-drivers
    ollietreend committed Mar 7, 2022
    Configuration menu
    Copy the full SHA
    50ed673 View commit details
    Browse the repository at this point in the history
  2. Release version 3.0.0

    ollietreend committed Mar 7, 2022
    Configuration menu
    Copy the full SHA
    03ca912 View commit details
    Browse the repository at this point in the history