Extend rendezvous hash testing
@@ -52,9 +52,8 @@ def test_rendezvous_redistribution():
# making this comparison
assert 0.31 < n_moved / n_keys < 0.35
# keys should move from the two original buckets with approximately
- # equal probability
- assert abs(from_bucket["b1"] - from_bucket["b2"]) < 10
-
- # use the standard deviation of the expected number of entries in each
- # bucket to get an idea for a reasonable (order of magnitude) difference
- assert abs(start_in["b1"] - start_in["b2"]) < (n_keys/2)**0.5
+ # equal probability. We pick 30 because it is "about right"
+ assert abs(from_bucket["b1"] - from_bucket["b2"]) < 30
+ # the initial distribution of keys should be roughly the same
+ # We pick 30 because it is "about right"
+ assert abs(start_in["b1"] - start_in["b2"]) < 30
