1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-10-31 08:37:45 +02:00

GitHub actions separate web tests (#2963)

Separating the web-tests from building the tests makes it more easy to
spot and override failing web-tests.

This is still testing only the English translation.

There are legitimate warnings coming out of the web-test infrastructure
and should be blocking. But sometimes the tests fail and need to be
overridden.
This commit is contained in:
michael-kerscher
2025-10-30 10:21:59 +01:00
committed by GitHub
parent d3fea80239
commit 6e862543d2

View File

@@ -149,20 +149,28 @@ jobs:
MDBOOK_BOOK__LANGUAGE: ${{ matrix.language }}
run: mdbook test
web-tests:
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Node
if: matrix.language == 'en'
uses: actions/setup-node@v5
with:
node-version: 22
cache: "npm"
cache-dependency-path: "tests/package-lock.json"
- name: Install test framework
if: matrix.language == 'en'
run: npm install
working-directory: ./tests
- name: Download english book
uses: actions/download-artifact@v6
with:
name: comprehensive-rust-en
path: book/
- name: Test Javascript
if: matrix.language == 'en'
run: cargo xtask web-tests --dir book/comprehensive-rust-${{ matrix.language }}/html
run: cargo xtask web-tests --dir book/comprehensive-rust-en/html
po-diff:
name: Translation diff