Skip to content

Commit a4f4e02

Browse files
committed
Add env for local testing
1 parent 9adb5c4 commit a4f4e02

File tree

2 files changed

+24
-1
lines changed

2 files changed

+24
-1
lines changed

docs/contributing.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,10 @@ like the following::
101101
$ source ~/pyenv/numcodecs-dev/bin/activate
102102
$ pip install -e .[docs,test,msgpack,zfpy]
103103

104+
You may need to initialize the submodule for c-blosc:
105+
106+
$ git submodule update --init --recursive
107+
104108
To verify that your development environment is working, you can run the unit tests::
105109

106110
$ pytest -v

pyproject.toml

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,20 +253,39 @@ conflicts = [
253253
]
254254
]
255255

256-
[tool.pixi.project]
256+
[tool.pixi.workspace]
257257
channels = ["conda-forge"]
258258
platforms = ["linux-64", "osx-arm64", "osx-64", "win-64"]
259259

260260
[tool.pixi.dependencies]
261+
python = "=3.13"
261262
clang = ">=19.1.7,<20"
262263
c-compiler = ">=1.9.0,<2"
263264
cxx-compiler = ">=1.9.0,<2"
264265
uv = "*"
265266

267+
[tool.pixi.feature.test.pypi-dependencies]
268+
numcodecs = { path = ".", editable = true, extras = ["test","test_extras","msgpack","pcodec","zfpy"] }
269+
270+
[tool.pixi.feature.test-google-crc32c.pypi-dependencies]
271+
numcodecs = { path = ".", editable = true, extras = ["google_crc32c"] }
272+
273+
[tool.pixi.feature.test-crc32c.pypi-dependencies]
274+
numcodecs = { path = ".", editable = true, extras = ["crc32c"] }
275+
276+
[tool.pixi.environments]
277+
default = { solve-group = "default" }
278+
test = ["test"]
279+
test-crc32c = ["test", "test-crc32c"]
280+
test-google-crc32c = ["test", "test-google-crc32c"]
281+
266282
[tool.pixi.tasks]
267283
ls-deps-312 = "uv run --group test-zarr-312 uv pip freeze"
268284
ls-deps-313 = "uv run --group test-zarr-313 uv pip freeze"
269285
ls-deps-main = "uv run --group test-zarr-main uv pip freeze"
270286
test-zarr-312 = "uv run --group test-zarr-312 pytest numcodecs/tests/test_zarr3.py numcodecs/tests/test_zarr3_import.py"
271287
test-zarr-313 = "uv run --group test-zarr-313 pytest numcodecs/tests/test_zarr3.py numcodecs/tests/test_zarr3_import.py"
272288
test-zarr-main = "uv run --group test-zarr-main pytest numcodecs/tests/test_zarr3.py numcodecs/tests/test_zarr3_import.py"
289+
290+
[tool.pixi.feature.test.tasks]
291+
run-tests = "pytest -v"

0 commit comments

Comments
 (0)