diff options
author | Pieter Wuille <pieter.wuille@gmail.com> | 2015-07-27 18:58:00 +0200 |
---|---|---|
committer | Pieter Wuille <pieter.wuille@gmail.com> | 2015-07-27 19:09:39 +0200 |
commit | d741371d7d27e228aa64c618c50b23fb5449c3e1 (patch) | |
tree | 0b292baaaabe5f9148db4813dad82c893dd04434 /src/test/bloom_tests.cpp | |
parent | d2d7ee0e863b286e1c9f9c54659d494fb0a7712d (diff) |
Only use randomly created nonces in CRollingBloomFilter.
Diffstat (limited to 'src/test/bloom_tests.cpp')
-rw-r--r-- | src/test/bloom_tests.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/bloom_tests.cpp b/src/test/bloom_tests.cpp index d927be6b81..6b30d6aa8a 100644 --- a/src/test/bloom_tests.cpp +++ b/src/test/bloom_tests.cpp @@ -469,7 +469,7 @@ static std::vector<unsigned char> RandomData() BOOST_AUTO_TEST_CASE(rolling_bloom) { // last-100-entry, 1% false positive: - CRollingBloomFilter rb1(100, 0.01, 1); + CRollingBloomFilter rb1(100, 0.01); // Overfill: static const int DATASIZE=399; @@ -500,7 +500,7 @@ BOOST_AUTO_TEST_CASE(rolling_bloom) BOOST_CHECK(nHits < 175); BOOST_CHECK(rb1.contains(data[DATASIZE-1])); - rb1.reset(1); + rb1.reset(); BOOST_CHECK(!rb1.contains(data[DATASIZE-1])); // Now roll through data, make sure last 100 entries @@ -527,7 +527,7 @@ BOOST_AUTO_TEST_CASE(rolling_bloom) BOOST_CHECK(nHits < 100); // last-1000-entry, 0.01% false positive: - CRollingBloomFilter rb2(1000, 0.001, 1); + CRollingBloomFilter rb2(1000, 0.001); for (int i = 0; i < DATASIZE; i++) { rb2.insert(data[i]); } |