Changeset View
Changeset View
Standalone View
Standalone View
test/functional/test_framework/util.py
Show First 20 Lines • Show All 266 Lines • ▼ Show 20 Lines | def wait_until(predicate, *, attempts=float('inf'), | ||||
raise RuntimeError('Unreachable') | raise RuntimeError('Unreachable') | ||||
# RPC/P2P connection constants and functions | # RPC/P2P connection constants and functions | ||||
############################################ | ############################################ | ||||
# The maximum number of nodes a single test can spawn | # The maximum number of nodes a single test can spawn | ||||
MAX_NODES = 12 | MAX_NODES = 12 | ||||
# Don't assign rpc or p2p ports lower than this | # Don't assign rpc or p2p ports lower than this (for example: 18333 is the | ||||
PORT_MIN = int(os.getenv('TEST_RUNNER_PORT_MIN', default=11000)) | # default testnet port) | ||||
PORT_MIN = int(os.getenv('TEST_RUNNER_PORT_MIN', default=20000)) | |||||
# The number of ports to "reserve" for p2p and rpc, each | # The number of ports to "reserve" for p2p and rpc, each | ||||
PORT_RANGE = 5000 | PORT_RANGE = 5000 | ||||
class PortSeed: | class PortSeed: | ||||
# Must be initialized with a unique integer for each process | # Must be initialized with a unique integer for each process | ||||
n = None | n = None | ||||
▲ Show 20 Lines • Show All 317 Lines • Show Last 20 Lines |