mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-29 09:34:09 +01:00
GPU Test Framework (#3873)
This commit is contained in:
1 parent
75989192a9
commit
543f921639
93 files changed
+3508
-2959
No files matched your search
@@ -270,17 +270,14 @@ jobs:
|
||||
# Windows
|
||||
- name: Windows x86_64
|
||||
os: windows-2022
|
||||
backends: dx12
|
||||
|
||||
# Mac
|
||||
- name: Mac aarch64
|
||||
os: [self-hosted, macOS]
|
||||
backends: vulkan metal
|
||||
|
||||
# Linux
|
||||
- name: Linux x86_64
|
||||
os: ubuntu-22.04
|
||||
backends: vulkan gl
|
||||
|
||||
name: Test ${{ matrix.name }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
@@ -294,16 +291,10 @@ jobs:
|
||||
with:
|
||||
tool: cargo-nextest,cargo-llvm-cov
|
||||
|
||||
- name: install swiftshader
|
||||
if: matrix.os == 'ubuntu-22.04'
|
||||
shell: bash
|
||||
- name: Install Repo MSRV toolchain
|
||||
run: |
|
||||
set -e
|
||||
|
||||
mkdir -p swiftshader
|
||||
curl -LsSf https://github.com/gfx-rs/ci-build/releases/latest/download/swiftshader-linux-x86_64.tar.xz | tar -xf - -C swiftshader
|
||||
|
||||
echo "VK_ICD_FILENAMES=$PWD/swiftshader/vk_swiftshader_icd.json" >> $GITHUB_ENV
|
||||
rustup toolchain install ${{ env.REPO_MSRV }} --no-self-update --profile=minimal
|
||||
cargo -V
|
||||
|
||||
- name: install llvmpipe, vulkan sdk
|
||||
if: matrix.os == 'ubuntu-22.04'
|
||||
@@ -317,8 +308,10 @@ jobs:
|
||||
wget -qO - https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo apt-key add -
|
||||
sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-jammy.list https://packages.lunarg.com/vulkan/lunarg-vulkan-jammy.list
|
||||
|
||||
sudo add-apt-repository ppa:kisak/kisak-mesa
|
||||
|
||||
sudo apt-get update
|
||||
sudo apt install -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev vulkan-sdk
|
||||
sudo apt install -y libegl1-mesa libgl1-mesa-dri libxcb-xfixes0-dev vulkan-sdk mesa-vulkan-drivers
|
||||
|
||||
- name: disable debug
|
||||
shell: bash
|
||||
@@ -334,22 +327,12 @@ jobs:
|
||||
with:
|
||||
key: test-${{ matrix.os }}-${{ env.CACHE_SUFFIX }}
|
||||
|
||||
- name: run wgpu-info
|
||||
shell: bash
|
||||
run: |
|
||||
set -e
|
||||
|
||||
cargo llvm-cov --no-cfg-coverage run --bin wgpu-info --no-report --features vulkan-portability
|
||||
|
||||
- name: run tests
|
||||
shell: bash
|
||||
run: |
|
||||
set -e
|
||||
|
||||
for backend in ${{ matrix.backends }}; do
|
||||
echo "======= NATIVE TESTS $backend ======";
|
||||
WGPU_BACKEND=$backend cargo llvm-cov --no-cfg-coverage nextest --no-fail-fast --no-report --features vulkan-portability
|
||||
done
|
||||
cargo xtask test --llvm-cov
|
||||
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: always() # We want artifacts even if the tests fail.
|
||||
@@ -421,6 +404,7 @@ jobs:
|
||||
- name: run rustfmt
|
||||
run: |
|
||||
cargo fmt -- --check
|
||||
cargo fmt --manifest-path xtask/Cargo.toml -- --check
|
||||
|
||||
check-cts-runner:
|
||||
name: Clippy cts_runner
|
||||
|
||||
Reference in new issue
Block a user