Add bitcoin-tx JSON tests
Zcash: Modified for us, and excluding test cases we don't have.
This commit is contained in:
parent
75f1a46023
commit
25193f0fa0
|
@ -1,18 +1,32 @@
|
|||
[
|
||||
{ "exec": "././zcash-tx",
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-create"],
|
||||
"output_cmp": "blanktx.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json","-create"],
|
||||
"output_cmp": "blanktx.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-"],
|
||||
"input": "blanktx.hex",
|
||||
"output_cmp": "blanktx.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json","-"],
|
||||
"input": "blanktx.hex",
|
||||
"output_cmp": "blanktx.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-", "delin=1"],
|
||||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-delin1-out.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json", "-", "delin=1"],
|
||||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-delin1-out.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-", "delin=31"],
|
||||
"input": "tx394b54bb.hex",
|
||||
|
@ -23,6 +37,11 @@
|
|||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-delout1-out.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json", "-", "delout=1"],
|
||||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-delout1-out.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-", "delout=2"],
|
||||
"input": "tx394b54bb.hex",
|
||||
|
@ -33,6 +52,11 @@
|
|||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-locktime317000-out.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json", "-", "locktime=317000"],
|
||||
"input": "tx394b54bb.hex",
|
||||
"output_cmp": "tt-locktime317000-out.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-create",
|
||||
|
@ -43,10 +67,25 @@
|
|||
"outaddr=4:t1g1aXFye74HKJ24VviTxo3AW4BZbyCni5H"],
|
||||
"output_cmp": "txcreate1.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-json",
|
||||
"-create",
|
||||
"in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0",
|
||||
"in=bf829c6bcf84579331337659d31f89dfd138f7f7785802d5501c92333145ca7c:18",
|
||||
"in=22a6f904655d53ae2ff70e701a0bbd90aa3975c0f40bfc6cc996a9049e31cdfc:1",
|
||||
"outaddr=0.18:t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb",
|
||||
"outaddr=4:t1g1aXFye74HKJ24VviTxo3AW4BZbyCni5H"],
|
||||
"output_cmp": "txcreate1.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-create", "outscript=0:"],
|
||||
"output_cmp": "txcreate2.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args": ["-json", "-create", "outscript=0:"],
|
||||
"output_cmp": "txcreate2.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-create",
|
||||
|
@ -57,6 +96,17 @@
|
|||
"outaddr=0.001:t1Ruz6gK4QPZoPPGpHaieupnnh62mktjQE7"],
|
||||
"output_cmp": "txcreatesign.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-json",
|
||||
"-create",
|
||||
"in=4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485:0",
|
||||
"set=privatekeys:[\"5HpHagT65TZzG1PH3CSu63k8DbpvD8s5ip4nEB3kEsreAnchuDf\"]",
|
||||
"set=prevtxs:[{\"txid\":\"4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485\",\"vout\":0,\"scriptPubKey\":\"76a91491b24bf9f5288532960ac687abb035127b1d28a588ac\"}]",
|
||||
"sign=1:ALL",
|
||||
"outaddr=0.001:t1Ruz6gK4QPZoPPGpHaieupnnh62mktjQE7"],
|
||||
"output_cmp": "txcreatesign.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-create",
|
||||
|
@ -64,10 +114,25 @@
|
|||
"outaddr=0.18:t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"],
|
||||
"output_cmp": "txcreatedata_seq0.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-json",
|
||||
"-create",
|
||||
"in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:4294967293",
|
||||
"outaddr=0.18:t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"],
|
||||
"output_cmp": "txcreatedata_seq0.json"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000",
|
||||
"in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:1"],
|
||||
"output_cmp": "txcreatedata_seq1.hex"
|
||||
},
|
||||
{ "exec": "./zcash-tx",
|
||||
"args":
|
||||
["-json",
|
||||
"01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000",
|
||||
"in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:1"],
|
||||
"output_cmp": "txcreatedata_seq1.json"
|
||||
}
|
||||
]
|
||||
|
|
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"txid": "d21633ba23f70118185227be58a63527675641ad37967e2aa461559f577aec43",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"vin": [
|
||||
],
|
||||
"vout": [
|
||||
],
|
||||
"hex": "01000000000000000000"
|
||||
}
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,63 @@
|
|||
{
|
||||
"txid": "f70f0d6c71416ed538e37549f430ab3665fee2437a42f10238c1bd490e782231",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"vin": [
|
||||
{
|
||||
"txid": "5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f",
|
||||
"vout": 0,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 4294967295
|
||||
},
|
||||
{
|
||||
"txid": "bf829c6bcf84579331337659d31f89dfd138f7f7785802d5501c92333145ca7c",
|
||||
"vout": 18,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 4294967295
|
||||
},
|
||||
{
|
||||
"txid": "22a6f904655d53ae2ff70e701a0bbd90aa3975c0f40bfc6cc996a9049e31cdfc",
|
||||
"vout": 1,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 4294967295
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 0.18,
|
||||
"n": 0,
|
||||
"scriptPubKey": {
|
||||
"asm": "OP_DUP OP_HASH160 1fc11f39be1729bf973a7ab6a615ca4729d64574 OP_EQUALVERIFY OP_CHECKSIG",
|
||||
"hex": "76a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac",
|
||||
"reqSigs": 1,
|
||||
"type": "pubkeyhash",
|
||||
"addresses": [
|
||||
"t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"value": 4.00,
|
||||
"n": 1,
|
||||
"scriptPubKey": {
|
||||
"asm": "OP_DUP OP_HASH160 f2d4db28cad6502226ee484ae24505c2885cb12d OP_EQUALVERIFY OP_CHECKSIG",
|
||||
"hex": "76a914f2d4db28cad6502226ee484ae24505c2885cb12d88ac",
|
||||
"reqSigs": 1,
|
||||
"type": "pubkeyhash",
|
||||
"addresses": [
|
||||
"t1g1aXFye74HKJ24VviTxo3AW4BZbyCni5H"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"hex": "01000000031f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000ffffffff7cca453133921c50d5025878f7f738d1df891fd359763331935784cf6b9c82bf1200000000fffffffffccd319e04a996c96cfc0bf4c07539aa90bd0b1a700ef72fae535d6504f9a6220100000000ffffffff0280a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac0084d717000000001976a914f2d4db28cad6502226ee484ae24505c2885cb12d88ac00000000"
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
"txid": "71603ccb1cd76d73d76eb6cfd5f0b9df6d65d90d76860ee52cb461c4be7032e8",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"vin": [
|
||||
{
|
||||
"txid": "5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f",
|
||||
"vout": 0,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 4294967293
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 0.18,
|
||||
"n": 0,
|
||||
"scriptPubKey": {
|
||||
"asm": "OP_DUP OP_HASH160 1fc11f39be1729bf973a7ab6a615ca4729d64574 OP_EQUALVERIFY OP_CHECKSIG",
|
||||
"hex": "76a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac",
|
||||
"reqSigs": 1,
|
||||
"type": "pubkeyhash",
|
||||
"addresses": [
|
||||
"t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"hex": "01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000"
|
||||
}
|
|
@ -0,0 +1,41 @@
|
|||
{
|
||||
"txid": "c4dea671b0d7b48f8ab10bc46650e8329d3c5766931f548f513847a19f5ba75b",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"vin": [
|
||||
{
|
||||
"txid": "5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f",
|
||||
"vout": 0,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 4294967293
|
||||
},
|
||||
{
|
||||
"txid": "5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f",
|
||||
"vout": 0,
|
||||
"scriptSig": {
|
||||
"asm": "",
|
||||
"hex": ""
|
||||
},
|
||||
"sequence": 1
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 0.18,
|
||||
"n": 0,
|
||||
"scriptPubKey": {
|
||||
"asm": "OP_DUP OP_HASH160 1fc11f39be1729bf973a7ab6a615ca4729d64574 OP_EQUALVERIFY OP_CHECKSIG",
|
||||
"hex": "76a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac",
|
||||
"reqSigs": 1,
|
||||
"type": "pubkeyhash",
|
||||
"addresses": [
|
||||
"t1LmWJddYzkTmTQjZrX7ZkFjmuEu5XKpGKb"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"hex": "01000000021f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff1f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000010000000180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000"
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
"txid": "977e7cd286cb72cd470d539ba6cb48400f8f387d97451d45cdb8819437a303af",
|
||||
"version": 1,
|
||||
"locktime": 0,
|
||||
"vin": [
|
||||
{
|
||||
"txid": "4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485",
|
||||
"vout": 0,
|
||||
"scriptSig": {
|
||||
"asm": "304502210096a75056c9e2cc62b7214777b3d2a592cfda7092520126d4ebfcd6d590c99bd8022051bb746359cf98c0603f3004477eac68701132380db8facba19c89dc5ab5c5e2[ALL] 0479be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",
|
||||
"hex": "48304502210096a75056c9e2cc62b7214777b3d2a592cfda7092520126d4ebfcd6d590c99bd8022051bb746359cf98c0603f3004477eac68701132380db8facba19c89dc5ab5c5e201410479be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8"
|
||||
},
|
||||
"sequence": 4294967295
|
||||
}
|
||||
],
|
||||
"vout": [
|
||||
{
|
||||
"value": 0.001,
|
||||
"n": 0,
|
||||
"scriptPubKey": {
|
||||
"asm": "OP_DUP OP_HASH160 5834479edbbe0539b31ffd3a8f8ebadc2165ed01 OP_EQUALVERIFY OP_CHECKSIG",
|
||||
"hex": "76a9145834479edbbe0539b31ffd3a8f8ebadc2165ed0188ac",
|
||||
"reqSigs": 1,
|
||||
"type": "pubkeyhash",
|
||||
"addresses": [
|
||||
"t1Ruz6gK4QPZoPPGpHaieupnnh62mktjQE7"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"hex": "01000000018594c5bdcaec8f06b78b596f31cd292a294fd031e24eec716f43dac91ea7494d000000008b48304502210096a75056c9e2cc62b7214777b3d2a592cfda7092520126d4ebfcd6d590c99bd8022051bb746359cf98c0603f3004477eac68701132380db8facba19c89dc5ab5c5e201410479be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8ffffffff01a0860100000000001976a9145834479edbbe0539b31ffd3a8f8ebadc2165ed0188ac00000000"
|
||||
}
|
Loading…
Reference in New Issue