Closed matheus23 closed 1 year ago
Merging #9 (96ef951) into main (a8cd85b) will decrease coverage by
0.18%
. The diff coverage is50.00%
.
@@ Coverage Diff @@
## main #9 +/- ##
==========================================
- Coverage 73.50% 73.33% -0.18%
==========================================
Files 5 5
Lines 117 120 +3
Branches 15 16 +1
==========================================
+ Hits 86 88 +2
Misses 21 21
- Partials 10 11 +1
Files Changed | Coverage Δ | |
---|---|---|
deterministic-bloom/src/runtime_size.rs | 77.77% <ø> (ø) |
|
deterministic-bloom/src/common.rs | 81.39% <50.00%> (-1.11%) |
:arrow_down: |
HashIndexIterator
used to loop infinitely whenbit_size
was 0, because it wouldn't be able to generate a random index that's< 0
(fair enough).Now it simply exists instantly if
bit_size == 0
.Also added a test case for empty blooms. They "technically" contain everything as a false positive. I opted for that, rather than "an empty bloom contains nothing", since that keeps the invariant that if you
.insert
something into a bloom filter, it will always becontain
ed.