aboutsummaryrefslogtreecommitdiff
path: root/test/functional/p2p_blockfilters.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/p2p_blockfilters.py')
-rwxr-xr-xtest/functional/p2p_blockfilters.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/functional/p2p_blockfilters.py b/test/functional/p2p_blockfilters.py
index e73fad439f..ef12b5f6b7 100755
--- a/test/functional/p2p_blockfilters.py
+++ b/test/functional/p2p_blockfilters.py
@@ -244,6 +244,23 @@ class CompactFiltersTest(BitcoinTestFramework):
peer_0.send_message(request)
peer_0.wait_for_disconnect()
+ self.log.info("Test -peerblockfilters without -blockfilterindex raises an error")
+ self.stop_node(0)
+ self.nodes[0].extra_args = ["-peerblockfilters"]
+ msg = "Error: Cannot set -peerblockfilters without -blockfilterindex."
+ self.nodes[0].assert_start_raises_init_error(expected_msg=msg)
+
+ self.log.info("Test unknown value to -blockfilterindex raises an error")
+ self.nodes[0].extra_args = ["-blockfilterindex=abc"]
+ msg = "Error: Unknown -blockfilterindex value abc."
+ self.nodes[0].assert_start_raises_init_error(expected_msg=msg)
+
+ self.log.info("Test -blockfilterindex with -reindex-chainstate raises an error")
+ self.nodes[0].assert_start_raises_init_error(
+ expected_msg='Error: -reindex-chainstate option is not compatible with -blockfilterindex. '
+ 'Please temporarily disable blockfilterindex while using -reindex-chainstate, or replace -reindex-chainstate with -reindex to fully rebuild all indexes.',
+ extra_args=['-blockfilterindex', '-reindex-chainstate'],
+ )
def compute_last_header(prev_header, hashes):
"""Compute the last filter header from a starting header and a sequence of filter hashes."""