mirror of
https://github.com/storytold/wgpu.git
synced 2026-12-01 18:43:52 +01:00
Revive the CTS job (#7675)
Includes the following minor functional fixes to deno_webgpu: * Don't throw an error immediately when `create_buffer` is called with invalid usage flags. * Implement `on_submitted_work_done`. * Correct validation of GPUExtent3D element count. * Run without tracing (instead of panic) if the DENO_WEBGPU_TRACE env var is not set. Fixes #6838
This commit is contained in:
1 parent
d7e6a0e1fa
commit
fd6f16f598
11 files changed
+184
-44
No files matched your search
@@ -0,0 +1,88 @@
|
||||
name: CTS
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [labeled, opened, synchronize]
|
||||
schedule:
|
||||
- cron: '33 2 * * *'
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
CARGO_INCREMENTAL: false
|
||||
CARGO_TERM_COLOR: always
|
||||
RUST_BACKTRACE: full
|
||||
MSRV: "1.84"
|
||||
|
||||
jobs:
|
||||
cts:
|
||||
# For pull requests, only run if we add the "PR: run CTS" label
|
||||
if: "github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'PR: run CTS')"
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
# Windows
|
||||
- name: Windows x86_64
|
||||
os: windows-2022
|
||||
target: x86_64-pc-windows-msvc
|
||||
backends: dx12
|
||||
|
||||
# Linux
|
||||
#- name: Linux x86_64
|
||||
# os: ubuntu-20.04
|
||||
# target: x86_64-unknown-linux-gnu
|
||||
# backends: vulkan # gl
|
||||
|
||||
name: CTS ${{ matrix.name }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
steps:
|
||||
- name: checkout repo
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
path: wgpu
|
||||
|
||||
- name: checkout cts
|
||||
run: |
|
||||
git clone https://github.com/gpuweb/cts.git
|
||||
cd cts
|
||||
git checkout $(cat ../wgpu/cts_runner/revision.txt)
|
||||
|
||||
- name: Install Repo MSRV toolchain
|
||||
run: |
|
||||
rustup toolchain install ${{ env.MSRV }} --no-self-update --profile=minimal --target ${{ matrix.target }}
|
||||
rustup override set ${{ env.MSRV }}
|
||||
cargo -V
|
||||
|
||||
- name: caching
|
||||
uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: cts-b # suffix for cache busting
|
||||
workspaces: wgpu
|
||||
|
||||
# We enable line numbers for panics, but that's it
|
||||
- name: disable debug
|
||||
shell: bash
|
||||
run: |
|
||||
mkdir -p wgpu/.cargo
|
||||
echo """[profile.dev]
|
||||
debug = 1" > wgpu/.cargo/config.toml
|
||||
|
||||
- name: build CTS runner
|
||||
run: |
|
||||
cargo build --manifest-path wgpu/cts_runner/Cargo.toml
|
||||
|
||||
- name: run CTS
|
||||
shell: bash
|
||||
run: |
|
||||
cd cts;
|
||||
for backend in ${{ matrix.backends }}; do
|
||||
echo "======= CTS TESTS $backend ======";
|
||||
grep -v '^//' ../wgpu/cts_runner/test.lst | while IFS=$' \t\r\n' read test; do
|
||||
echo "=== Running $test ===";
|
||||
DENO_WEBGPU_BACKEND=$backend cargo run --manifest-path ../wgpu/cts_runner/Cargo.toml --frozen -- ./tools/run_deno --verbose "$test";
|
||||
done
|
||||
done
|
||||
echo;
|
||||
echo "Note: Summary reflects only the last test suite, not the entire run."
|
||||
Reference in new issue
Block a user