mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-05-31 23:00:53 +00:00
test_happiness: limit string sizes to 30 chars
I think these are supposed to represent share ids or server ids, so we don't need to exercise them being too huge.
This commit is contained in:
parent
11c39325fb
commit
74e7ef4b98
@ -222,8 +222,8 @@ class Happiness(unittest.TestCase):
|
|||||||
class PlacementTests(unittest.TestCase):
|
class PlacementTests(unittest.TestCase):
|
||||||
|
|
||||||
@given(
|
@given(
|
||||||
sets(elements=text(min_size=1), min_size=4, max_size=4),
|
sets(elements=text(min_size=1, max_size=30), min_size=4, max_size=4),
|
||||||
sets(elements=text(min_size=1), min_size=4),
|
sets(elements=text(min_size=1, max_size=30), min_size=4),
|
||||||
)
|
)
|
||||||
@settings(suppress_health_check=[HealthCheck.too_slow])
|
@settings(suppress_health_check=[HealthCheck.too_slow])
|
||||||
def test_hypothesis_unhappy(self, peers, shares):
|
def test_hypothesis_unhappy(self, peers, shares):
|
||||||
@ -241,9 +241,9 @@ class PlacementTests(unittest.TestCase):
|
|||||||
assert happiness == 4
|
assert happiness == 4
|
||||||
|
|
||||||
@given(
|
@given(
|
||||||
sets(elements=text(min_size=1), min_size=1, max_size=10),
|
sets(elements=text(min_size=1, max_size=30), min_size=1, max_size=10),
|
||||||
# can we make a readonly_peers that's a subset of ^
|
# can we make a readonly_peers that's a subset of ^
|
||||||
sets(elements=text(min_size=1), min_size=1, max_size=20),
|
sets(elements=text(min_size=1, max_size=30), min_size=1, max_size=20),
|
||||||
)
|
)
|
||||||
@settings(suppress_health_check=[HealthCheck.too_slow])
|
@settings(suppress_health_check=[HealthCheck.too_slow])
|
||||||
def test_more_hypothesis(self, peers, shares):
|
def test_more_hypothesis(self, peers, shares):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user