Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
cd665a586c
  1. 2
      crypto777/m_js
  2. 4
      iguana/m_js
  3. 2
      iguana/secp256k1/m_js
  4. 8
      iguana/swaps/iguana_BTCswap.c
  5. 2
      iguana/tests/buy
  6. 1
      iguana/tests/buy2
  7. 1
      iguana/tests/encryptwallet2
  8. 2
      iguana/tests/sell
  9. 1
      iguana/tests/sell2

2
crypto777/m_js

@ -1,4 +1,4 @@
git pull
rm *.o
emcc -c -s USE_PTHREADS=1 -s ALLOW_MEMORY_GROWTH=1 -O2 *.c jpeg/*.c jpeg/unix/*.c
emcc -c -s USE_PTHREADS=1 *.c jpeg/*.c jpeg/unix/*.c
rm -f ../agents/libcrypto777.a; emar rcu ../agents/libcrypto777.a *.o

4
iguana/m_js

@ -1,7 +1,5 @@
rm ../agents/iguana *.o
git pull
cd secp256k1; ./m_js; cd ..
emcc -s USE_PTHREADS=1 -s ALLOW_MEMORY_GROWTH=1 -Wno-deprecated -c -O2 *.c databases/iguana_DB.c
#emcc -s USE_PTHREADS=1 -Wno-deprecated -c main.c iguana777.c iguana_bundles.c
emcc -s USE_PTHREADS=1 -s ALLOW_MEMORY_GROWTH=1 -o iguana.html -O2 *.o ../agents/libcrypto777.a -lm
emcc -s USE_PTHREADS=1 -o iguana.html *.c databases/iguana_DB.c ../agents/libcrypto777.a -lm
cp iguana.html iguana.js pthread-main.js iguana.html.mem /var/www/html

2
iguana/secp256k1/m_js

@ -1 +1 @@
emcc -c -o ../secp256k1.o -s USE_PTHREADS=1 -s ALLOW_MEMORY_GROWTH=1 -I. -I./src -I./include -I./src -O3 -W -std=c89 -pedantic -Wall -Wextra -Wcast-align -Wnested-externs -Wshadow -Wstrict-prototypes -Wno-unused-function -Wno-long-long -Wno-overlength-strings -fvisibility=hidden -DHAVE_CONFIG_H src/secp256k1.c
emcc -c -o ../secp256k1.o -s USE_PTHREADS=1 -I. -I./src -I./include -I./src -W -std=c89 -pedantic -Wall -Wextra -Wcast-align -Wnested-externs -Wshadow -Wstrict-prototypes -Wno-unused-function -Wno-long-long -Wno-overlength-strings -fvisibility=hidden -DHAVE_CONFIG_H src/secp256k1.c

8
iguana/swaps/iguana_BTCswap.c

@ -393,7 +393,7 @@ int32_t instantdex_pubkeyargs(struct supernet_info *myinfo,struct bitcoin_swapin
{
pubi = instantdex_derivekeypair(myinfo,&swap->privkeys[n],pubkey,privkey,hash);
privkey = swap->privkeys[n];
//printf("i.%d n.%d numpubs.%d %02x vs %02x\n",i,n,numpubs,pubkey[0],firstbyte);
printf("i.%d n.%d numpubs.%d %02x vs %02x\n",i,n,numpubs,pubkey[0],firstbyte);
if ( pubkey[0] != firstbyte )
continue;
if ( n < 2 && numpubs > 2 )
@ -406,12 +406,6 @@ int32_t instantdex_pubkeyargs(struct supernet_info *myinfo,struct bitcoin_swapin
{
calc_rmd160_sha256(secret160,swap->privkeys[n].bytes,sizeof(swap->privkeys[n]));
memcpy(&txid,secret160,sizeof(txid));
/*txid = (m+1) | ((m+1)<<16);
txid <<= 32;
txid = (m+1) | ((m+1)<<16);
pubi.txid = (m+1) | ((m+1)<<16);
pubi.txid <<= 32;
pubi.txid = (m+1) | ((m+1)<<16);*/
len += iguana_rwnum(1,(uint8_t *)&swap->deck[m][0],sizeof(txid),&txid);
len += iguana_rwnum(1,(uint8_t *)&swap->deck[m][1],sizeof(pubi.txid),&pubi.txid);
m++;

2
iguana/tests/buy

@ -1 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"buy\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0027,\"volume\":1.0}"
curl --url "http://127.0.0.1:7778" --data "{\"password\":\"test\",\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"buy\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0029,\"volume\":1.0}"

1
iguana/tests/buy2

@ -0,0 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"password\":\"test2\",\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"buy\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0027,\"volume\":1.0}"

1
iguana/tests/encryptwallet2

@ -0,0 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"agent\":\"bitcoinrpc\",\"method\":\"encryptwallet\",\"passphrase\":\"test2\"}"

2
iguana/tests/sell

@ -1 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"sell\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0029,\"volume\":1.0}"
curl --url "http://127.0.0.1:7778" --data "{\"password\":\"test\",\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"sell\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0029,\"volume\":1.0}"

1
iguana/tests/sell2

@ -0,0 +1 @@
curl --url "http://127.0.0.1:7778" --data "{\"password\":\"test2\",\"password\":\"test\",\"dotrade\":1,\"agent\":\"InstantDEX\",\"exchange\":\"bitcoin\",\"method\":\"sell\",\"base\":\"BTCD\",\"rel\":\"BTC\",\"price\":0.0029,\"volume\":1.0}"
Loading…
Cancel
Save