github.com/koko1123/flow-go-1@v0.29.6/utils/unittest/staker.go (about) 1 package unittest 2 3 import ( 4 "github.com/koko1123/flow-go-1/model/flow" 5 ) 6 7 type FixedStaker struct { 8 Staked bool 9 } 10 11 func NewFixedStaker(initial bool) *FixedStaker { 12 return &FixedStaker{ 13 Staked: initial, 14 } 15 } 16 17 func (f *FixedStaker) AmIStakedAt(_ flow.Identifier) bool { 18 return f.Staked 19 }