Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[tests] Make comp test framework more debuggable #11468

Merged
merged 1 commit into from Nov 10, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 5 additions & 5 deletions test/functional/test_framework/comptool.py
Expand Up @@ -295,8 +295,11 @@ def run(self):
# Wait until verack is received
self.wait_for_verack()

test_number = 1
for test_instance in self.test_generator.get_tests():
test_number = 0
tests = self.test_generator.get_tests()
for test_instance in tests:
test_number += 1
logger.info("Running test %d: %s line %s" % (test_number, tests.gi_code.co_filename, tests.gi_frame.f_lineno))
# We use these variables to keep track of the last block
# and last transaction in the tests, which are used
# if we're not syncing on every block or every tx.
Expand Down Expand Up @@ -397,9 +400,6 @@ def run(self):
if (not self.check_mempool(tx.sha256, tx_outcome)):
raise AssertionError("Mempool test failed at test %d" % test_number)

logger.info("Test %d: PASS" % test_number)
test_number += 1

[ c.disconnect_node() for c in self.connections ]
self.wait_for_disconnections()
self.block_store.close()
Expand Down