Update Chromium version in DDEV selenium add-on
Define newer Chromium version #
Some time ago, I wrote an article about how to set up codeception acceptance tests, using the DDEV selenium add-on. Unfortunately, the DDEV selenium plugin currently uses a pretty old Chromium version per default at the moment.
But you easily change to any Chromium version, which you prefer.
First of all, go to https://hub.docker.com/r/seleniarm/standalone-chromium/tags and find the tag of the Chromium image,
you would like to use. I highly recommend to use any static version and not only latest
. Using the dynamic tag latest
could cause unexpected side effects and even different behavior on your and your coworkers machines.
After you have chosen your Chromium tag, change the corresponding line in the file .ddev/docker-compose.selenium-chrome.yaml
:
services:
selenium-chrome:
- image: seleniarm/standalone-chromium:4.1.4-20220429
+ image: seleniarm/standalone-chromium:124.0
After changing this line, you need to restart your DDEV project with ddev restart
, which will pull and use the newer image.
Fix configuration #
This already could be all steps, you need to do, but there is one small additional thing: At some point in the past,
the syntax to pass arguments to Chromium changed from chromeOptions
to goog:chromeOptions
. If you still use the old
syntax in cour codeception configuration, you need to update this line. In my example, the configuration was located in
the file acceptance.suite.yml
:
modules:
config:
WebDriver:
host: selenium-chrome
browser: chrome
capabilities:
- chromeOptions:
+ goog:chromeOptions:
args:
- '--ignore-certificate-errors'
- '--disable-dev-shm-usage'