From 83528cc050fa15592eaa5fd0a33a4a170bc2c9b9 Mon Sep 17 00:00:00 2001 From: Brian Ginsburg <7957636+bgins@users.noreply.github.com> Date: Mon, 31 Jul 2023 09:02:01 -0700 Subject: [PATCH] fix: Fix GitHub action headless browser tests (#120) * ci: fix headless browser tests * ci: try setup-chromedriver action --- .github/workflows/run_test_suite.yaml | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/.github/workflows/run_test_suite.yaml b/.github/workflows/run_test_suite.yaml index 424466e2..16e20c77 100644 --- a/.github/workflows/run_test_suite.yaml +++ b/.github/workflows/run_test_suite.yaml @@ -89,21 +89,8 @@ jobs: WASM_BINDGEN_VERSION=`toml get ./Cargo.lock . | jq '.package | map(select(.name == "wasm-bindgen"))[0].version' | xargs echo` cargo install wasm-bindgen-cli --vers "$WASM_BINDGEN_VERSION" - # See: https://github.com/SeleniumHQ/selenium/blob/5d108f9a679634af0bbc387e7e3811bc1565912b/.github/actions/setup-chrome/action.yml - name: Setup Chrome and Chromedriver - run: | - wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - - echo "deb http://dl.google.com/linux/chrome/deb/ stable main" | sudo tee -a /etc/apt/sources.list.d/google-chrome.list - sudo apt-get update -qqy - sudo apt-get -qqy install google-chrome-stable - CHROME_VERSION=$(google-chrome-stable --version) - CHROME_FULL_VERSION=${CHROME_VERSION%%.*} - CHROME_MAJOR_VERSION=${CHROME_FULL_VERSION//[!0-9]} - sudo rm /etc/apt/sources.list.d/google-chrome.list - export CHROMEDRIVER_VERSION=`curl -s https://chromedriver.storage.googleapis.com/LATEST_RELEASE_${CHROME_MAJOR_VERSION%%.*}` - curl -L -O "https://chromedriver.storage.googleapis.com/${CHROMEDRIVER_VERSION}/chromedriver_linux64.zip" - unzip chromedriver_linux64.zip && chmod +x chromedriver && sudo mv chromedriver /usr/local/bin - chromedriver -version + uses: nanasess/setup-chromedriver@v2 - name: Run Rust Headless Browser Tests run: CHROMEDRIVER=/usr/local/bin/chromedriver cargo test --target wasm32-unknown-unknown