diff options
author | MarcoFalke <falke.marco@gmail.com> | 2022-03-31 08:37:27 +0200 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2022-03-31 08:37:30 +0200 |
commit | c8ac7e6a651333494269c19a55fce2307534825e (patch) | |
tree | 253e1e74b26ddddc2dc1cec8bac74f422cea8361 /test | |
parent | e1e6a3386fc7be6c65ee0b452263ea29c799eb0e (diff) | |
parent | d6bc2322ed2e0674e027d39825fdadbb0db2c24a (diff) |
Merge bitcoin/bitcoin#24698: test: -peerblockfilters without -blockfilterindex raises an error
d6bc2322ed2e0674e027d39825fdadbb0db2c24a test: -peerblockfilters without -blockfilterindex raises an error (brunoerg)
Pull request description:
This PR adds test coverage for the following init error:
https://github.com/bitcoin/bitcoin/blob/2a3e8fb3592e42300ec96c9f6724e15346e30ea7/src/init.cpp#L850
Setting -peerblockfilters without -blockfilterindex should raise an error when initializing.
ACKs for top commit:
ccdle12:
Tested ACK https://github.com/bitcoin/bitcoin/pull/24698/commits/d6bc2322ed2e0674e027d39825fdadbb0db2c24a
Tree-SHA512: e740c2ccde6bb1bb8381bb676a6d01bd5746cf9ce0c8dadd62067a6b9b380027bfe8b8cdeae9846a0ab18385f3dc5dff607fe5274cb55107d47470db00015fb2
Diffstat (limited to 'test')
-rwxr-xr-x | test/functional/p2p_blockfilters.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/p2p_blockfilters.py b/test/functional/p2p_blockfilters.py index e73fad439f..e45cef65bd 100755 --- a/test/functional/p2p_blockfilters.py +++ b/test/functional/p2p_blockfilters.py @@ -244,6 +244,12 @@ 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) + def compute_last_header(prev_header, hashes): """Compute the last filter header from a starting header and a sequence of filter hashes.""" |