this is for flood test, 200 transfer everytime
#!/usr/bin/expect -f
set timeout -1
set wallet_name "default"
set account_from "alt"
set account_to "delegate-alt"
set loop_time 100
send_user "wallet name is: $wallet_name\n"
send_user "wallet passphrase: "
stty -echo
expect_user -re "(.*)\n"
stty echo
set wallet_pass $expect_out(1,string)
spawn ./bitshares_client --server --httpport 9989
expect -exact "--- there are now 1 active connections to the p2p network"
expect -exact "(wallet closed) >>> "
send -- "info\r"
expect -exact "(wallet closed) >>> "
send -- "wallet_open $wallet_name\r"
expect -exact "$wallet_name (locked) >>> "
send -- "wallet_unlock 999999\r"
expect -exact "passphrase: "
send -- "$wallet_pass\r"
#expect -exact "$wallet_name (unlocked) >>> "
#send -- "wallet_rescan_blockchain\r"
sleep 2
for {set i 1} {$i < $loop_time} {incr i 1} {
expect -exact "$wallet_name (unlocked) >>> "
send -- "wallet_transfer 10 DRINK $account_from $account_to \"test flood...\"\r"
expect -exact "$wallet_name (unlocked) >>> "
send -- "wallet_transfer 11 DRINK $account_from $account_to \"test flood...\"\r"
}
expect -exact "$wallet_name (unlocked) >>>
send -- "wallet_account_transaction_history\r"
interact