account permissions and some gendoug

This commit is contained in:
Ethan Buchman
2015-05-12 20:40:19 -04:00
committed by Jae Kwon
parent 3468956e1f
commit a0f3b94e83
9 changed files with 421 additions and 23 deletions

View File

@ -25,10 +25,11 @@ func Tempfile(prefix string) (*os.File, string) {
func RandAccount(randBalance bool, minBalance int64) (*account.Account, *account.PrivAccount) {
privAccount := account.GenPrivAccount()
acc := &account.Account{
Address: privAccount.PubKey.Address(),
PubKey: privAccount.PubKey,
Sequence: RandInt(),
Balance: minBalance,
Address: privAccount.PubKey.Address(),
PubKey: privAccount.PubKey,
Sequence: RandInt(),
Balance: minBalance,
Permissions: account.DefaultPermissions,
}
if randBalance {
acc.Balance += int64(RandUint32())