aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoss Nicoll <[email protected]>2021-06-02 23:22:44 +0100
committerGitHub <[email protected]>2021-06-02 23:22:44 +0100
commitd069588c1fdfe1a3c87858ce1c1deae44cdc8a40 (patch)
treecd41b1cf1853e05d5a1f64ae4eb6e7bcd54e7fd1
parentMerge pull request #1828 from rnicoll/1.21-dev-scrypt-algo (diff)
parentfix: reduce tests latency (diff)
downloadarchived-discoin-d069588c1fdfe1a3c87858ce1c1deae44cdc8a40.tar.xz
archived-discoin-d069588c1fdfe1a3c87858ce1c1deae44cdc8a40.zip
Merge pull request #2224 from mmicael1/1.21-reduce-tests-latency
fix: reduce tests latency
-rwxr-xr-xtest/functional/test_framework/test_framework.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/functional/test_framework/test_framework.py b/test/functional/test_framework/test_framework.py
index f42f279cc..79106a39e 100755
--- a/test/functional/test_framework/test_framework.py
+++ b/test/functional/test_framework/test_framework.py
@@ -42,6 +42,8 @@ class TestStatus(Enum):
TEST_EXIT_PASSED = 0
TEST_EXIT_FAILED = 1
TEST_EXIT_SKIPPED = 77
+# REDUCE WAIT LATENCY
+DEFAULT_WAIT = .1
TMPDIR_PREFIX = "bitcoin_func_test_"
@@ -597,7 +599,7 @@ class BitcoinTestFramework(metaclass=BitcoinTestMetaClass):
self.connect_nodes(1, 2)
self.sync_all()
- def sync_blocks(self, nodes=None, wait=1, timeout=60):
+ def sync_blocks(self, nodes=None, wait=DEFAULT_WAIT, timeout=60):
"""
Wait until everybody has the same tip.
sync_blocks needs to be called with an rpc_connections set that has least
@@ -619,7 +621,7 @@ class BitcoinTestFramework(metaclass=BitcoinTestMetaClass):
"".join("\n {!r}".format(b) for b in best_hash),
))
- def sync_mempools(self, nodes=None, wait=1, timeout=60, flush_scheduler=True):
+ def sync_mempools(self, nodes=None, wait=DEFAULT_WAIT, timeout=60, flush_scheduler=True):
"""
Wait until everybody has the same transactions in their memory
pools