Skip to content

Commit

Permalink
test_numbertheory: make test coverage realistic
Browse files Browse the repository at this point in the history
  • Loading branch information
tomato42 committed Feb 24, 2023
1 parent 62f8e7c commit 27db17c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ecdsa/test_numbertheory.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ def st_comp_with_com_fac(draw):
# select at most 20 lists (returned numbers),
# each having at most 30 primes (factors) including none (then the number
# will be 1)
comp_primes = draw(
comp_primes = draw( # pragma: no branch
st.integers(min_value=1, max_value=20).flatmap(
lambda n: st.lists(
st.lists(st.sampled_from(primes), max_size=30),
Expand Down Expand Up @@ -225,7 +225,7 @@ def st_comp_no_com_fac(draw):

# select at most 20 lists, each having at most 30 primes
# selected from the leftover_primes list
number_primes = draw(
number_primes = draw( # pragma: no branch
st.integers(min_value=1, max_value=20).flatmap(
lambda n: st.lists(
st.lists(st.sampled_from(leftover_primes), max_size=30),
Expand Down

0 comments on commit 27db17c

Please sign in to comment.