From b1a5b1bbefd2b93a34ab103618c00bd5972ea7b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wojciech=20Tyczy=C5=84ski?= Date: Tue, 8 Aug 2023 20:30:40 +0200 Subject: [PATCH] ci: run tests in Docker (#5440) This PR adds Chromium with webdriver to the Docker image, so it's now possible to run at least some subset of tests using Docker env. Additionally, Alpine version has been bumped up, so recent version of Chromium can be used. --- build/docker/Dockerfile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/build/docker/Dockerfile b/build/docker/Dockerfile index cb9c5d42a5..05fdcd7f04 100644 --- a/build/docker/Dockerfile +++ b/build/docker/Dockerfile @@ -2,14 +2,17 @@ # docker build -t shaka-player-build /path/to/shaka-player/build/docker # Run with: # docker run -v /path/to/shaka-player:/usr/src --user $(id -u):$(id -g) shaka-player-build +# Run tests with: +# docker run -v /path/to/shaka-player:/usr/src --user $(id -u):$(id -g) shaka-player-build python3 build/test.py --quick --browsers ChromeHeadless -FROM alpine:3.14 +FROM alpine:3.18 # Install dependencies RUN apk add --update --no-cache \ - bash git nodejs npm openjdk11-jre-headless python3 + bash chromium chromium-chromedriver git nodejs npm openjdk11-jre-headless python3 WORKDIR /usr/src ENV HOME /tmp +ENV CHROMEDRIVER_PATH /usr/bin/chromedriver CMD ["python3", "build/all.py"]