more obvious failure for ethtest

This commit is contained in:
obscuren
2015-03-12 23:26:58 +01:00
parent 3a88da578f
commit 80592f244d
4 changed files with 9 additions and 10 deletions

View File

@ -36,10 +36,12 @@ type Account interface {
SubBalance(amount *big.Int)
AddBalance(amount *big.Int)
Balance() *big.Int
Address() []byte
}
// generic transfer method
func Transfer(from, to Account, amount *big.Int) error {
//fmt.Printf(":::%x::: %v < %v\n", from.Address(), from.Balance(), amount)
if from.Balance().Cmp(amount) < 0 {
return errors.New("Insufficient balance in account")
}