Skip to content

Commit

Permalink
Add additional guard for "no NVIDIA driver"
Browse files Browse the repository at this point in the history
  • Loading branch information
akx authored and Titus-von-Koeller committed Mar 11, 2024
1 parent 62249b4 commit 2416dd3
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ def pytest_runtest_call(item):
if str(ae) == "Torch not compiled with CUDA enabled":
pytest.skip("Torch not compiled with CUDA enabled")
raise
except RuntimeError as re:
# CUDA-enabled Torch build, but no CUDA-capable device found
if "Found no NVIDIA driver on your system" in str(re):
pytest.skip("No NVIDIA driver found")
raise


@pytest.fixture(scope="session")
Expand Down

0 comments on commit 2416dd3

Please sign in to comment.