MCPcopy Create free account
hub / github.com/ElementsProject/elements / run_unsafe_tests

Method run_unsafe_tests

test/functional/rpc_psbt.py:576–583  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

574
575
576 def run_unsafe_tests(self):
577 # Make sure unsafe inputs are included if specified
578 self.nodes[2].createwallet(wallet_name="unsafe")
579 wunsafe = self.nodes[2].get_wallet_rpc("unsafe")
580 self.nodes[0].sendtoaddress(wunsafe.getnewaddress(), 2)
581 self.sync_mempools()
582 assert_raises_rpc_error(-4, "Insufficient funds", wunsafe.walletcreatefundedpsbt, [], [{self.nodes[0].getnewaddress(): 1}])
583 wunsafe.walletcreatefundedpsbt([], [{self.nodes[0].getnewaddress(): 1}], 0, {"include_unsafe": True})
584
585
586 # BIP 174 tests are disabled because they don't work with CA yet. Comment the function so it doesn't flag lint as unused.

Callers 1

run_testMethod · 0.95

Calls 4

assert_raises_rpc_errorFunction · 0.90
createwalletMethod · 0.80
sync_mempoolsMethod · 0.80
get_wallet_rpcMethod · 0.45

Tested by

no test coverage detected