Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
6b6a1ebf82
  1. 5
      iguana/iguana_payments.c
  2. 1
      iguana/tests/createrawtransactionT
  3. 2
      iguana/tests/decoderawtransaction

5
iguana/iguana_payments.c

@ -945,8 +945,9 @@ ARRAY_OBJ_INT(bitcoinrpc,createrawtransaction,vins,vouts,locktime)
iguana_createvins(myinfo,coin,txobj,vins); iguana_createvins(myinfo,coin,txobj,vins);
if ( (n= cJSON_GetArraySize(vouts)) > 0 ) if ( (n= cJSON_GetArraySize(vouts)) > 0 )
{ {
if ( (item= vouts->child) != 0 && n == 1 ) if ( vouts->child != 0 && n == 1 )
item = item->child; item = vouts->child;
else item = vouts;
while ( item != 0 ) while ( item != 0 )
{ {
if ( (field= jfieldname(item)) != 0 ) if ( (field= jfieldname(item)) != 0 )

1
iguana/tests/createrawtransactionT

@ -0,0 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"method\":\"createrawtransaction\",\"params\":[[{\"txid\":\"2196c07f71f206728301b03ffbffb7fd383744d03c1a3e0a1e03b6fb9ffd4ece\",\"vout\":1}], {\"1E4EadLDvqRWgSPRLqTM5YXefdaxsPPZVs\":0.009}] }"

2
iguana/tests/decoderawtransaction

@ -1 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"method\":\"decoderawtransaction\",\"params\":[\"0100000093b7325701f6d17d847b7096cdd9b79e4df4b74aabb9ac34b7abd4f9fce19d761e97cca0e80000000000ffffffff0240420f00000000001976a91410acba3a841fae68aba4b5ff162714c493bcc04e88acd0300e00000000001976a914d8b8c039206af6cec82bca950f592801e62808cb88ac00000000\"]}" curl --url "http://127.0.0.1:7778" --data "{\"method\":\"decoderawtransaction\",\"params\":[\"0100000051e2335701ce4efd9ffbb6031e0a3e1a3cd0443738fdb7fffb3fb001837206f2717fc096210100000000ffffffff0000000000\"]}"

Loading…
Cancel
Save