github HypothesisWorks/hypothesis hypothesis-python-6.18.0
Hypothesis for Python - version 6.18.0

latest releases: hypothesis-python-6.105.1, hypothesis-python-6.105.0, hypothesis-python-6.104.4...
2 years ago

This release teaches "from_type()" a neat trick: when resolving an
"typing.Annotated" type, if one of the annotations is a strategy
object we use that as the inferred strategy. For example:

PositiveInt = Annotated[int, st.integers(min_value=1)]

If there are multiple strategies, we use the last outer-most
annotation. See issue #2978 and pull request #3082 for discussion.

Requires Python 3.9 or later for "get_type_hints(...,
include_extras=False)".

The canonical version of these notes (with links) is on readthedocs.

Don't miss a new hypothesis release

NewReleases is sending notifications on new releases.