0g-chain/tests/util/strings.go
Robert Pirtle 5cfa33f638
test(e2e): lower cost to run on live networks (#1646)
* add cost summary to e2e test suite runs

* lower cost of test

* refactor initial funding to use new BankSend()

* reduce gas used for initial funding

* return all sdk funds on shutdown

* enable refunds when running against live network

* save more cosmos coins! require less total overall

* track erc20s on Chain

* refactor erc20 funding with new TransferErc20()

* return all registered erc20 balance

* lower erc20 e2e test values

* withdraw earn position & convert back to erc20

* lower gas fees in e2e tests

* fix env variable typo

* add readme note about how to run on live network

* log total spend required for e2e tests
2023-06-29 22:30:02 -07:00

21 lines
336 B
Go

package util
import (
"fmt"
"strings"
sdk "github.com/cosmos/cosmos-sdk/types"
)
func PrettyPrintCoins(coins sdk.Coins) string {
if len(coins) == 0 {
return ""
}
out := make([]string, 0, len(coins))
for _, coin := range coins {
out = append(out, coin.String())
}
return fmt.Sprintf("- %s", strings.Join(out, "\n- "))
}