Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changes/+c563f4d4.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Register 'gpu' marker with pytest for downstream StoreTests.
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ exclude_lines = [
[tool.coverage.run]
omit = [
"bench/compress_normal.py",
"src/zarr/testing/conftest.py", # only for downstream projects
]

[tool.hatch]
Expand Down Expand Up @@ -455,3 +456,6 @@ issue_format = ":issue:`{issue}`"

[tool.codespell]
ignore-words-list = "astroid"

[project.entry-points.pytest11]
zarr = "zarr.testing"
9 changes: 9 additions & 0 deletions src/zarr/testing/conftest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import pytest


def pytest_configure(config: pytest.Config) -> None:
# The tests in zarr.testing are intended to be run by downstream projects.
# To allow those downstream projects to run with `--strict-markers`, we need
# to register an entry point with pytest11 and register our "plugin" with it,
# which just registers the markers used in zarr.testing
config.addinivalue_line("markers", "gpu: mark a test as requiring CuPy and GPU")