Skip to content

Commit

Permalink
Fixes #12 where hypothesis lists strategy no longer worked after up…
Browse files Browse the repository at this point in the history
…dating hypothesis version.
  • Loading branch information
MetinSa committed Mar 22, 2024
1 parent 3d80175 commit f5f723b
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
27 changes: 14 additions & 13 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ mkdocstrings = "^0.23.0"
mkdocstrings-python = "^1.7.3"
ruff = "^0.1.4"
markdown = "<3.4.0"
hypothesis = "<=6.47.5"
hypothesis = "6.99.11"


[build-system]
Expand Down
2 changes: 1 addition & 1 deletion tests/_strategies.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def pixels(draw: DrawFn, nside: int) -> int | list[int] | npt.NDArray[np.integer

shape = draw(integers(min_value=1, max_value=npix - 1))

list_stategy = lists(pixel_strategy, min_size=shape, max_size=shape)
list_stategy = lists(pixel_strategy, min_size=1)
array_strategy = arrays(dtype=int, shape=shape, elements=pixel_strategy)

return draw(one_of(pixel_strategy, list_stategy, array_strategy))
Expand Down

0 comments on commit f5f723b

Please sign in to comment.