diff --git a/test/scripts/e2e_subs/dynamic-fee-teal-test.sh b/test/scripts/e2e_subs/dynamic-fee-teal-test.sh index 1b91eb8067..62b8a5956b 100755 --- a/test/scripts/e2e_subs/dynamic-fee-teal-test.sh +++ b/test/scripts/e2e_subs/dynamic-fee-teal-test.sh @@ -11,10 +11,10 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') -ACCOUNTC=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') -ACCOUNTD=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') +ACCOUNTC=$(${gcmd} account new|awk '{ print $6 }') +ACCOUNTD=$(${gcmd} account new|awk '{ print $6 }') ZERO_ADDRESS=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY5HFKQ LEASE=uImiLf+mqOqs0BFsqIUHBh436N/z964X50e3P9Ii4ac= diff --git a/test/scripts/e2e_subs/e2e_teal.sh b/test/scripts/e2e_subs/e2e_teal.sh index 96dfe83586..ebde271fac 100755 --- a/test/scripts/e2e_subs/e2e_teal.sh +++ b/test/scripts/e2e_subs/e2e_teal.sh @@ -11,11 +11,11 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') # prints: # Created new account with address UCTHHNBEAUWHDQWQI5DGQCTB7AR4CSVNU5YNPROAYQIT3Y3LKVDFAA5M6Q -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') TIMEOUT_ROUND=$((${ROUND} + 7)) @@ -25,7 +25,7 @@ python ${GOPATH}/src/github.com/algorand/go-algorand/data/transactions/logic/tlh cat ${TEMPDIR}/tlhc.teal -ACCOUNT_TLHC=$(${gcmd} clerk compile -n ${TEMPDIR}/tlhc.teal|tee /dev/tty|awk '{ print $2 }') +ACCOUNT_TLHC=$(${gcmd} clerk compile -n ${TEMPDIR}/tlhc.teal|awk '{ print $2 }') ${gcmd} clerk send --amount 1000000 --from ${ACCOUNT} --to ${ACCOUNT_TLHC} @@ -63,10 +63,10 @@ set -e ${gcmd} clerk send --amount 1000000 --from ${ACCOUNT} --to ${ACCOUNT_TLHC} # timeout round should pass. some of the 35 seconds was eaten by prior ops. -CROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') +CROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') while [ $CROUND -lt $TIMEOUT_ROUND ]; do goal node wait - CROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') + CROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') done ${gcmd} clerk send --from-program ${TEMPDIR}/tlhc.teal --to ${ACCOUNT} --close-to ${ACCOUNT} --amount 1 --argb64 AA== @@ -87,7 +87,7 @@ ${gcmd} clerk rawsend -f ${TEMPDIR}/one.stx ${gcmd} clerk dryrun -t ${TEMPDIR}/one.stx -ACCOUNT_TRUE=$(${gcmd} clerk compile -n ${TEMPDIR}/true.teal|tee /dev/tty|awk '{ print $2 }') +ACCOUNT_TRUE=$(${gcmd} clerk compile -n ${TEMPDIR}/true.teal|awk '{ print $2 }') ${gcmd} clerk send --amount 1000000 --from ${ACCOUNT} --to ${ACCOUNT_TRUE} @@ -103,9 +103,9 @@ ${gcmd} clerk inspect ${TEMPDIR}/true.stx ${gcmd} clerk compile -D ${TEMPDIR}/true.lsig -ACCOUNTC=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNTC=$(${gcmd} account new|awk '{ print $6 }') -ACCOUNTM=$(${gcmd} account multisig new -T 2 ${ACCOUNT} ${ACCOUNTB} ${ACCOUNTC}|tee /dev/tty|awk '{ print $6 }') +ACCOUNTM=$(${gcmd} account multisig new -T 2 ${ACCOUNT} ${ACCOUNTB} ${ACCOUNTC}|awk '{ print $6 }') ${gcmd} clerk multisig signprogram -p ${TEMPDIR}/true.teal -a ${ACCOUNT} -A ${ACCOUNTM} -o ${TEMPDIR}/mtrue.lsig diff --git a/test/scripts/e2e_subs/htlc-teal-test.sh b/test/scripts/e2e_subs/htlc-teal-test.sh index b15d667e25..e450a7fcf0 100755 --- a/test/scripts/e2e_subs/htlc-teal-test.sh +++ b/test/scripts/e2e_subs/htlc-teal-test.sh @@ -11,8 +11,8 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') ZERO_ADDRESS=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY5HFKQ LEASE=YmxhaCBibGFoIGxlYXNlIHdoYXRldmVyIGJsYWghISE= @@ -20,7 +20,7 @@ LEASE=YmxhaCBibGFoIGxlYXNlIHdoYXRldmVyIGJsYWghISE= algotmpl -d ${GOPATH}/src/github.com/algorand/go-algorand/tools/teal/templates/ htlc --fee=2000 --hashfn="sha256" --hashimg="9S+9MrKzuG/4jvbEkGKChfSCrxXdyylUH5S89Saj9sc=" --own=${ACCOUNT} --rcv=${ACCOUNTB} --timeout=100000 > ${TEMPDIR}/atomic.teal # Compile the template -CONTRACT=$(${gcmd} clerk compile ${TEMPDIR}/atomic.teal |tee /dev/tty| awk '{ print $2 }') +CONTRACT=$(${gcmd} clerk compile ${TEMPDIR}/atomic.teal | awk '{ print $2 }') # Fund the contract ${gcmd} clerk send -a 10000000 -f ${ACCOUNT} -t ${CONTRACT} @@ -45,7 +45,7 @@ fi ${gcmd} clerk send --fee=1000 --from-program ${TEMPDIR}/atomic.teal -a=0 -t=${ZERO_ADDRESS} --close-to=${ACCOUNTB} --argb64=aHVudGVyMg== # Check balance -BALANCEB=$(${gcmd} account balance -a ${ACCOUNTB} |tee /dev/tty| awk '{ print $1 }') +BALANCEB=$(${gcmd} account balance -a ${ACCOUNTB} | awk '{ print $1 }') if [ $BALANCEB -ne 9999000 ]; then date '+htlc-teal-test FAIL wanted balance=9999000 but got ${BALANCEB} %Y%m%d_%H%M%S' false diff --git a/test/scripts/e2e_subs/keyreg-teal-test.sh b/test/scripts/e2e_subs/keyreg-teal-test.sh index b61d21ba28..b807fe4841 100755 --- a/test/scripts/e2e_subs/keyreg-teal-test.sh +++ b/test/scripts/e2e_subs/keyreg-teal-test.sh @@ -11,9 +11,9 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') -ACCOUNTA=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') +ACCOUNTA=$(${gcmd} account new|awk '{ print $6 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') LEASE=YmxhaCBibGFoIGxlYXNlIHdoYXRldmVyIGJsYWghISE= DUR=4 @@ -41,7 +41,7 @@ EOF PBOUND=$(cat ${TEMPDIR}/pbound) while [ ${ROUND} != ${PBOUND} ]; do goal node wait - ROUND=$(goal node status |tee /dev/tty| grep 'Last committed block:'|awk '{ print $4 }') + ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') done echo "send a bad keyreg transaction (missing lease)" @@ -89,7 +89,7 @@ ${gcmd} account changeonlinestatus -a ${ACCOUNTA} -x ${LEASE} --online --firstva dsign ${TEMPDIR}/delegate.keyregkey ${TEMPDIR}/kr.lsig < ${TEMPDIR}/keyreg.tx > ${TEMPDIR}/keyreg.stx ${gcmd} clerk rawsend -f ${TEMPDIR}/keyreg.stx -REGOK=$(${gcmd} account list |tee /dev/tty| grep ${ACCOUNTA} | awk '{ print $1 }' | grep -c online) +REGOK=$(${gcmd} account list | grep ${ACCOUNTA} | awk '{ print $1 }' | grep -c online) if [[ $REGOK != 1 ]]; then date '+keyreg-teal-test FAIL correct keyreg transaction failed %Y%m%d_%H%M%S' false @@ -125,10 +125,10 @@ if [[ $RES != 'Participation key generation successful' ]]; then fi echo "wait for valid duration to pass" -ROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') +ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') while [ ${ROUND} -lt `expr ${EXPIRE} + 1` ]; do goal node wait - ROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') + ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') done echo "send a keyreg transaction after expiration" diff --git a/test/scripts/e2e_subs/limit-swap-test.sh b/test/scripts/e2e_subs/limit-swap-test.sh index b010b5b115..9a7c2acb65 100755 --- a/test/scripts/e2e_subs/limit-swap-test.sh +++ b/test/scripts/e2e_subs/limit-swap-test.sh @@ -11,7 +11,7 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') ZERO_ADDRESS=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY5HFKQ ${gcmd} asset create --creator ${ACCOUNT} --name bogocoin --unitname bogo --total 1000000000000 @@ -23,7 +23,7 @@ ASSET_ID=$(${gcmd} asset info --creator $ACCOUNT --asset bogo|grep 'Asset ID'|aw echo "closeout part a, Algo trader" # quick expiration, test closeout -ROUND=$(goal node status |tee /dev/tty| grep 'Last committed block:'|awk '{ print $4 }') +ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') TIMEOUT_ROUND=$((${ROUND} + 2)) sed s/TMPL_ASSET/${ASSET_ID}/g < ${GOPATH}/src/github.com/algorand/go-algorand/tools/teal/templates/limit-order-a.teal.tmpl | sed s/TMPL_SWAPN/31337/g | sed s/TMPL_SWAPD/137/g | sed s/TMPL_TIMEOUT/${TIMEOUT_ROUND}/g | sed s/TMPL_OWN/${ACCOUNT}/g | sed s/TMPL_FEE/100000/g | sed s/TMPL_MINTRD/10000/g > ${TEMPDIR}/limit-order-a.teal @@ -66,10 +66,10 @@ ${gcmd} clerk rawsend -f ${TEMPDIR}/b-asset-init.stx echo "fund account with asset" ${gcmd} asset send --assetid ${ASSET_ID} -f ${ACCOUNT} -t ${ACCOUNT_ASSET_TRADER} -a 1000000 -ROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') +ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') while [ $ROUND -lt $TIMEOUT_ROUND ]; do goal node wait - ROUND=$(goal node status | grep 'Last committed block:'|tee /dev/tty|awk '{ print $4 }') + ROUND=$(goal node status | grep 'Last committed block:'|awk '{ print $4 }') done echo "recover asset" @@ -116,7 +116,7 @@ echo "make Algo trader" sed s/TMPL_ASSET/${ASSET_ID}/g < ${GOPATH}/src/github.com/algorand/go-algorand/tools/teal/templates/limit-order-a.teal.tmpl | sed s/TMPL_SWAPN/31337/g | sed s/TMPL_SWAPD/137/g | sed s/TMPL_TIMEOUT/${TIMEOUT_ROUND}/g | sed s/TMPL_OWN/${ACCOUNT}/g | sed s/TMPL_FEE/100000/g | sed s/TMPL_MINTRD/10000/g > ${TEMPDIR}/limit-order-a.teal -ACCOUNT_ALGO_TRADER=$(${gcmd} clerk compile ${TEMPDIR}/limit-order-a.teal -o ${TEMPDIR}/limit-order-a.tealc|tee /dev/tty|awk '{ print $2 }') +ACCOUNT_ALGO_TRADER=$(${gcmd} clerk compile ${TEMPDIR}/limit-order-a.teal -o ${TEMPDIR}/limit-order-a.tealc|awk '{ print $2 }') echo "setup trader with Algos" ${gcmd} clerk send --amount 100000000 --from ${ACCOUNT} --to ${ACCOUNT_ALGO_TRADER} diff --git a/test/scripts/e2e_subs/periodic-teal-test.sh b/test/scripts/e2e_subs/periodic-teal-test.sh index 1ccee6dcc3..35ffe62325 100755 --- a/test/scripts/e2e_subs/periodic-teal-test.sh +++ b/test/scripts/e2e_subs/periodic-teal-test.sh @@ -11,14 +11,14 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') ZERO_ADDRESS=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAY5HFKQ LEASE=YmxhaCBibGFoIGxlYXNlIHdoYXRldmVyIGJsYWghISE= sed s/TMPL_RCV/${ACCOUNTB}/g < ${GOPATH}/src/github.com/algorand/go-algorand/tools/teal/templates/periodic-payment-escrow.teal.tmpl | sed s/TMPL_PERIOD/5/g | sed s/TMPL_DUR/2/g | sed s/TMPL_AMT/1000000/g | sed s/TMPL_LEASE/${LEASE}/g | sed s/TMPL_TIMEOUT/16/g | sed s/TMPL_FEE/10000/g > ${TEMPDIR}/periodic.teal -ACCOUNT_PERIODIC=$(${gcmd} clerk compile ${TEMPDIR}/periodic.teal -o ${TEMPDIR}/periodic.tealc|tee /dev/tty|awk '{ print $2 }') +ACCOUNT_PERIODIC=$(${gcmd} clerk compile ${TEMPDIR}/periodic.teal -o ${TEMPDIR}/periodic.tealc|awk '{ print $2 }') ROUND=5 DUR_ROUND=$((${ROUND} + 2)) diff --git a/test/scripts/e2e_subs/teal-split-test.sh b/test/scripts/e2e_subs/teal-split-test.sh index 03c6658500..2377574fe7 100755 --- a/test/scripts/e2e_subs/teal-split-test.sh +++ b/test/scripts/e2e_subs/teal-split-test.sh @@ -11,14 +11,14 @@ WALLET=$1 gcmd="goal -w ${WALLET}" -ACCOUNT=$(${gcmd} account list|tee /dev/tty|awk '{ print $3 }') +ACCOUNT=$(${gcmd} account list|awk '{ print $3 }') -ACCOUNTB=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') -ACCOUNTC=$(${gcmd} account new|tee /dev/tty|awk '{ print $6 }') +ACCOUNTB=$(${gcmd} account new|awk '{ print $6 }') +ACCOUNTC=$(${gcmd} account new|awk '{ print $6 }') sed s/TMPL_RCV1/${ACCOUNTB}/g < ${GOPATH}/src/github.com/algorand/go-algorand/tools/teal/templates/split.teal.tmpl | sed s/TMPL_RCV2/${ACCOUNTC}/g | sed s/TMPL_RAT1/60/g | sed s/TMPL_RAT2/40/g | sed s/TMPL_MINPAY/100000/g | sed s/TMPL_TIMEOUT/4/g | sed s/TMPL_OWN/${ACCOUNTB}/g | sed s/TMPL_FEE/10000/g > ${TEMPDIR}/split.teal -ACCOUNT_SPLIT=$(${gcmd} clerk compile ${TEMPDIR}/split.teal -o ${TEMPDIR}/split.tealc|tee /dev/tty|awk '{ print $2 }') +ACCOUNT_SPLIT=$(${gcmd} clerk compile ${TEMPDIR}/split.teal -o ${TEMPDIR}/split.tealc|awk '{ print $2 }') ${gcmd} clerk send -a 60000000 -f $ACCOUNT_SPLIT -t $ACCOUNTB -o ${TEMPDIR}/b.tx ${gcmd} clerk send -a 40000000 -f $ACCOUNT_SPLIT -t $ACCOUNTC -o ${TEMPDIR}/c.tx @@ -37,8 +37,8 @@ ${gcmd} clerk send -a 110000000 -f ${ACCOUNT} -t ${ACCOUNT_SPLIT} ${gcmd} clerk rawsend -f ${TEMPDIR}/group.stx -BALANCEB=$(${gcmd} account balance -a ${ACCOUNTB}|tee /dev/tty|awk '{ print $1 }') -BALANCEC=$(${gcmd} account balance -a ${ACCOUNTC}|tee /dev/tty|awk '{ print $1 }') +BALANCEB=$(${gcmd} account balance -a ${ACCOUNTB}|awk '{ print $1 }') +BALANCEC=$(${gcmd} account balance -a ${ACCOUNTC}|awk '{ print $1 }') if [ $BALANCEB -ne 60000000 ]; then echo bad balance B ${BALANCEB}