Fix feature_txindex.py

This commit is contained in:
UdjinM6 2020-10-22 20:44:59 +03:00 committed by pasta
parent 3cc35ea470
commit aafa64d021
No known key found for this signature in database
GPG Key ID: 52527BEDABE87984

View File

@ -37,12 +37,12 @@ class TxIndexTest(BitcoinTestFramework):
def run_test(self): def run_test(self):
self.log.info("Test that settings can't be changed without -reindex...") self.log.info("Test that settings can't be changed without -reindex...")
self.stop_node(1) self.stop_node(1)
self.assert_start_raises_init_error(1, ["-txindex=0"], 'You need to rebuild the database using -reindex to change -txindex') self.nodes[1].assert_start_raises_init_error(["-txindex=0"], "You need to rebuild the database using -reindex to change -txindex")
self.start_node(1, ["-txindex=0", "-reindex"]) self.start_node(1, ["-txindex=0", "-reindex"])
connect_nodes(self.nodes[0], 1) connect_nodes(self.nodes[0], 1)
self.sync_all() self.sync_all()
self.stop_node(1) self.stop_node(1)
self.assert_start_raises_init_error(1, ["-txindex"], 'You need to rebuild the database using -reindex to change -txindex') self.nodes[1].assert_start_raises_init_error(["-txindex"], "You need to rebuild the database using -reindex to change -txindex")
self.start_node(1, ["-txindex", "-reindex"]) self.start_node(1, ["-txindex", "-reindex"])
connect_nodes(self.nodes[0], 1) connect_nodes(self.nodes[0], 1)
self.sync_all() self.sync_all()