Litecoin: Functional tests

pull/751/head
Adrian Gallagher 4 years ago
parent 36830b02e1
commit 60fb716792
No known key found for this signature in database
GPG Key ID: FE3348877809386C

@ -35,13 +35,13 @@ class DumptxoutsetTest(BitcoinTestFramework):
# Blockhash should be deterministic based on mocked time.
assert_equal(
out['base_hash'],
'6fd417acba2a8738b06fee43330c50d58e6a725046c3d843c8dd7e51d46d1ed6')
'3bc56dc7255f129e7ae88ebe791e131b0a813cc5254d629ee79c28c4191aefe7')
with open(str(expected_path), 'rb') as f:
digest = hashlib.sha256(f.read()).hexdigest()
# UTXO snapshot hash should be deterministic based on mocked time.
assert_equal(
digest, 'be032e5f248264ba08e11099ac09dbd001f6f87ffc68bf0f87043d8146d50664')
digest, 'f1d6826ce1b9463355e2000d93797939940a9d5d83df3c53e504310dc7c13001')
# Specifying a path to an existing file will fail.
assert_raises_rpc_error(

@ -565,7 +565,7 @@ class PSBTTest(BitcoinTestFramework):
assert_equal(analysis['error'], 'PSBT is not valid. Input 0 spends unspendable output')
self.log.info("PSBT with invalid values should have error message and Creator as next")
analysis = self.nodes[0].analyzepsbt('cHNidP8BAHECAAAAAfA00BFgAm6tp86RowwH6BMImQNL5zXUcTT97XoLGz0BAAAAAAD/////AgD5ApUAAAAAFgAUKNw0x8HRctAgmvoevm4u1SbN7XL87QKVAAAAABYAFPck4gF7iL4NL4wtfRAKgQbghiTUAAAAAAABAR8AgIFq49AHABYAFJUDtxf2PHo641HEOBOAIvFMNTr2AAAA')
analysis = self.nodes[0].analyzepsbt('cHNidP8BAHECAAAAARNTpt5oa3uwxMzxURUM6jlpiSkLFrX06npUFpCPa1GiAAAAAAD/////AgD5ApUAAAAAFgAUPkSFny4xIZ2VJ5hIR8fDbnIlHU787QKVAAAAABYAFNxIPry2sJUX1zcEDniawrFS6fllAAAAAAABAR8AQJd4tDIeABYAFBxnjRVdozgnm1ESsG9AvaDvLUsLAAAA')
assert_equal(analysis['next'], 'creator')
assert_equal(analysis['error'], 'PSBT is not valid. Input 0 has invalid value')
@ -573,7 +573,7 @@ class PSBTTest(BitcoinTestFramework):
analysis = self.nodes[0].analyzepsbt('cHNidP8BAHECAAAAAZYezcxdnbXoQCmrD79t/LzDgtUo9ERqixk8wgioAobrAAAAAAD9////AlDDAAAAAAAAFgAUy/UxxZuzZswcmFnN/E9DGSiHLUsuGPUFAAAAABYAFLsH5o0R38wXx+X2cCosTMCZnQ4baAAAAAABAR8A4fUFAAAAABYAFOBI2h5thf3+Lflb2LGCsVSZwsltIgIC/i4dtVARCRWtROG0HHoGcaVklzJUcwo5homgGkSNAnJHMEQCIGx7zKcMIGr7cEES9BR4Kdt/pzPTK3fKWcGyCJXb7MVnAiALOBgqlMH4GbC1HDh/HmylmO54fyEy4lKde7/BT/PWxwEBAwQBAAAAIgYC/i4dtVARCRWtROG0HHoGcaVklzJUcwo5homgGkSNAnIYDwVpQ1QAAIABAACAAAAAgAAAAAAAAAAAAAAiAgL+CIiB59NSCssOJRGiMYQK1chahgAaaJpIXE41Cyir+xgPBWlDVAAAgAEAAIAAAACAAQAAAAAAAAAA')
assert_equal(analysis['next'], 'finalizer')
analysis = self.nodes[0].analyzepsbt('cHNidP8BAHECAAAAAfA00BFgAm6tp86RowwH6BMImQNL5zXUcTT97XoLGz0BAAAAAAD/////AgCAgWrj0AcAFgAUKNw0x8HRctAgmvoevm4u1SbN7XL87QKVAAAAABYAFPck4gF7iL4NL4wtfRAKgQbghiTUAAAAAAABAR8A8gUqAQAAABYAFJUDtxf2PHo641HEOBOAIvFMNTr2AAAA')
analysis = self.nodes[0].analyzepsbt('cHNidP8BAHECAAAAAcmWU+VDKCo8Sg9LWNvSyrFzJsCKFqhvnu7MGsgFSF5sAAAAAAD/////AgBAl3i0Mh4AFgAUxNi6bFXuvWW7rTH3sS3livOrL0H87QKVAAAAABYAFBH4DLF7oFcgIdVPC7M1gHd3gxk4AAAAAAABAR8A8gUqAQAAABYAFHlKJcETQ72199/8asaiI/btMfB6AAAA')
assert_equal(analysis['next'], 'creator')
assert_equal(analysis['error'], 'PSBT is not valid. Output amount invalid')

Loading…
Cancel
Save