Merge #6322: backport: Merge bitcoin/bitcoin#25034: test: add missing stop_node calls to feature_coinstatsindex and feature_prune

766c2c2757 Merge bitcoin/bitcoin#25034: test: add missing stop_node calls to feature_coinstatsindex and feature_prune (MacroFake)

Pull request description:

  ## Issue being fixed or feature implemented
  #6316 follow-up

  ## What was done?

  ## How Has This Been Tested?

  ## Breaking Changes

  ## Checklist:
  - [ ] I have performed a self-review of my own code
  - [ ] I have commented my code, particularly in hard-to-understand areas
  - [ ] I have added or updated relevant unit/integration/functional/e2e tests
  - [ ] I have made corresponding changes to the documentation
  - [ ] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_

ACKs for top commit:
  knst:
    ACK 766c2c2757
  kwvg:
    utACK 766c2c2757
  PastaPastaPasta:
    utACK 766c2c2757

Tree-SHA512: f2ea80f427ae7fbff0fec570e5a34c98da165dff50a1012398d60d6253b4a2defbe74a7c35ebe49d086724e590d5d684bd1ecd3cd988a5639cfa88606f4f9975
This commit is contained in:
pasta 2024-10-15 09:31:03 -05:00
commit d62fa7c0d9
No known key found for this signature in database
GPG Key ID: E2F3D7916E722D38
2 changed files with 3 additions and 0 deletions

View File

@ -253,11 +253,13 @@ class CoinStatsIndexTest(BitcoinTestFramework):
self.log.info("Test that -reindex-chainstate is disallowed with coinstatsindex") self.log.info("Test that -reindex-chainstate is disallowed with coinstatsindex")
self.stop_node(1)
self.nodes[1].assert_start_raises_init_error( self.nodes[1].assert_start_raises_init_error(
expected_msg='Error: -reindex-chainstate option is not compatible with -coinstatsindex. ' expected_msg='Error: -reindex-chainstate option is not compatible with -coinstatsindex. '
'Please temporarily disable coinstatsindex while using -reindex-chainstate, or replace -reindex-chainstate with -reindex to fully rebuild all indexes.', 'Please temporarily disable coinstatsindex while using -reindex-chainstate, or replace -reindex-chainstate with -reindex to fully rebuild all indexes.',
extra_args=['-coinstatsindex', '-reindex-chainstate'], extra_args=['-coinstatsindex', '-reindex-chainstate'],
) )
self.restart_node(1, extra_args=["-coinstatsindex"])
def _test_use_index_option(self): def _test_use_index_option(self):
self.log.info("Test use_index option for nodes running the index") self.log.info("Test use_index option for nodes running the index")

View File

@ -564,6 +564,7 @@ class TestNode():
Will throw if dashd starts without an error. Will throw if dashd starts without an error.
Will throw if an expected_msg is provided and it does not match dashd's stdout.""" Will throw if an expected_msg is provided and it does not match dashd's stdout."""
assert not self.running
with tempfile.NamedTemporaryFile(dir=self.stderr_dir, delete=False) as log_stderr, \ with tempfile.NamedTemporaryFile(dir=self.stderr_dir, delete=False) as log_stderr, \
tempfile.NamedTemporaryFile(dir=self.stdout_dir, delete=False) as log_stdout: tempfile.NamedTemporaryFile(dir=self.stdout_dir, delete=False) as log_stdout:
try: try: