chore: Format and fix lints (#9336)

* make format

Signed-off-by: Thane Thomson <connect@thanethomson.com>

* Fix linting directives

Signed-off-by: Thane Thomson <connect@thanethomson.com>

* make mockery

Signed-off-by: Thane Thomson <connect@thanethomson.com>

* Appease CI linter

Signed-off-by: Thane Thomson <connect@thanethomson.com>

* Appease CI linter

Signed-off-by: Thane Thomson <connect@thanethomson.com>

Signed-off-by: Thane Thomson <connect@thanethomson.com>
This commit is contained in:
Thane Thomson
2022-08-30 12:28:46 -04:00
committed by GitHub
parent 7b40167f58
commit cceea4de22
87 changed files with 402 additions and 384 deletions
+7 -6
View File
@@ -1,4 +1,3 @@
//nolint: gosec
package e2e
import (
@@ -26,9 +25,11 @@ const (
networkIPv6 = "fd80:b10c::/48"
)
type Mode string
type Protocol string
type Perturbation string
type (
Mode string
Protocol string
Perturbation string
)
const (
ModeValidator Mode = "validator"
@@ -396,7 +397,7 @@ func (t Testnet) ArchiveNodes() []*Node {
// RandomNode returns a random non-seed node.
func (t Testnet) RandomNode() *Node {
for {
node := t.Nodes[rand.Intn(len(t.Nodes))]
node := t.Nodes[rand.Intn(len(t.Nodes))] //nolint:gosec
if node.Mode != ModeSeed {
return node
}
@@ -459,7 +460,7 @@ type keyGenerator struct {
func newKeyGenerator(seed int64) *keyGenerator {
return &keyGenerator{
random: rand.New(rand.NewSource(seed)),
random: rand.New(rand.NewSource(seed)), //nolint:gosec
}
}