Change Transaction.example to ensure uniqueness

This commit is contained in:
Mark Spanbroek 2021-06-30 13:55:45 +02:00
parent c054636381
commit b0b40d3829
1 changed files with 2 additions and 2 deletions

View File

@ -15,13 +15,13 @@ proc example*(_: type Wallet): Wallet =
proc example*(_: type Transaction): Transaction =
let alice = PublicKey.alice
let bob = PublicKey.bob
let carol = PublicKey.example
let victor = PublicKey.victor
let genesis = Transaction.genesis
let amount = rand(100).u256
var transaction = !Transaction.init(
{genesis.hash: alice},
{bob: amount, alice: 100.u256 - amount},
{carol: amount, alice: 100.u256 - amount},
victor
)
transaction