aboutsummaryrefslogtreecommitdiffstats
path: root/core/negative-ack_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'core/negative-ack_test.go')
-rw-r--r--core/negative-ack_test.go7
1 files changed, 2 insertions, 5 deletions
diff --git a/core/negative-ack_test.go b/core/negative-ack_test.go
index 87fcea0..990871e 100644
--- a/core/negative-ack_test.go
+++ b/core/negative-ack_test.go
@@ -23,7 +23,7 @@ import (
"github.com/stretchr/testify/suite"
- "github.com/dexon-foundation/dexon-consensus-core/common"
+ "github.com/dexon-foundation/dexon-consensus-core/core/test"
"github.com/dexon-foundation/dexon-consensus-core/core/types"
)
@@ -84,10 +84,7 @@ func genTimestamp(vids []types.ValidatorID, a []int) map[types.ValidatorID]time.
}
func genTestNegativeAck(num int) (*negativeAck, []types.ValidatorID) {
- vids := []types.ValidatorID{}
- for i := 0; i < num; i++ {
- vids = append(vids, types.ValidatorID{Hash: common.NewRandomHash()})
- }
+ vids := test.GenerateRandomValidatorIDs(num)
n := newNegativeAck(vids[0])
for i := 1; i < num; i++ {
n.addValidator(vids[i])