diff --git a/qa/rpc-tests/feature_fedpeg.py b/qa/rpc-tests/feature_fedpeg.py index 89551a39565..37841c354e1 100755 --- a/qa/rpc-tests/feature_fedpeg.py +++ b/qa/rpc-tests/feature_fedpeg.py @@ -57,9 +57,16 @@ def setup_network(self, split=False): "-port=" + str(p2p_port(0)), "-rpcport=" + str(rpc_port(0)), "-addresstype=legacy", - "-deprecatedrpc=validateaddress" + "-deprecatedrpc=validateaddress", + "-bech32_hrp=sb", + "-pchmessagestart=F0C7706A", + "-pubkeyprefix=125", + "-scriptprefix=87", + "-secretprefix=217", + "-extpubkeyprefix=043587CF", + "-extprvkeyprefix=04358394", ] - temp_node = start_node(0, self.options.tmpdir, temp_args, binary=self.binary, chain='signet', cookie_auth=True) + temp_node = start_node(0, self.options.tmpdir, temp_args, binary=self.binary, chain='temp', cookie_auth=True) addr = temp_node.getnewaddress() k = key.CECKey() pub = temp_node.validateaddress(addr)["pubkey"] @@ -67,13 +74,13 @@ def setup_network(self, split=False): pubkey = key.CPubKey(k.get_pubkey()) wif = temp_node.dumpprivkey(addr) stop_node(temp_node, 0) - shutil.rmtree(os.path.join(self.options.tmpdir, 'node0', 'signet')) script = script.CScript([pubkey, script.OP_CHECKSIG]) blockscript = hexlify(script).decode('ascii') print('blockscript', blockscript) print('wif', wif) + self.parent_chain = self.options.parent_type # Parent chain args for n in range(2): # We want to test the rpc cookie method so we force the use of a @@ -88,24 +95,28 @@ def setup_network(self, split=False): "-addresstype=legacy", # To make sure bitcoind gives back p2pkh no matter version "-deprecatedrpc=validateaddress", "-port="+str(p2p_port(n)), - "-rpcport="+str(rpc_port(n)) + "-rpcport="+str(rpc_port(n)), ]) elif self.options.parent_type == 'signet': - self.parent_chain = 'signet' rpc_u, rpc_p = rpc_auth_pair(n) self.extra_args.append([ "-printtoconsole=0", "-signet_blockscript=%s" % blockscript, "-signet_siglen=77", - "-signet_seednode=178.128.221.177", "-port=" + str(p2p_port(n)), "-rpcport=" + str(rpc_port(n)), "-addresstype=legacy", # To make sure bitcoind gives back p2pkh no matter version "-deprecatedrpc=validateaddress", "-fallbackfee=0.00001", + "-bech32_hrp=sb", + "-pchmessagestart=F0C7706A", + "-pubkeyprefix=125", + "-scriptprefix=87", + "-secretprefix=217", + "-extpubkeyprefix=043587CF", + "-extprvkeyprefix=04358394", ]) elif self.options.parent_type == 'elements': - self.parent_chain = 'parent' self.extra_args.append([ "-conf=dummy", "-printtoconsole=0", @@ -113,7 +124,7 @@ def setup_network(self, split=False): '-anyonecanspendaremine', '-initialfreecoins=2100000000000000', "-port="+str(p2p_port(n)), - "-rpcport="+str(rpc_port(n)) + "-rpcport="+str(rpc_port(n)), ]) # Only first parent uses name/password, the 2nd uses cookie auth if not use_cookie_auth: diff --git a/qa/rpc-tests/test_framework/util.py b/qa/rpc-tests/test_framework/util.py index e01bced50d8..4a00365e1ad 100644 --- a/qa/rpc-tests/test_framework/util.py +++ b/qa/rpc-tests/test_framework/util.py @@ -348,7 +348,7 @@ def start_node(i, dirname, extra_args=None, rpchost=None, timewait=None, binary= if binary is None: binary = os.getenv("ELEMENTSD", "elementsd") args = [ binary, "-datadir="+datadir, "-server", "-keypool=1", "-discover=0", "-rest", "-mocktime="+str(get_mocktime()) ] - args.append('-regtest' if chain == 'regtest' else '-signet' if chain == 'signet' else '-chain=' + chain) + args.append('-regtest' if chain == 'regtest' else '-chain=' + chain) if extra_args is not None: args.extend(extra_args) bitcoind_processes[i] = subprocess.Popen(args) if os.getenv("PYTHON_DEBUG", ""):