mirror of
https://github.com/minio/minio.git
synced 2025-11-07 21:02:58 -05:00
Run modernize (#21546)
`go run golang.org/x/tools/gopls/internal/analysis/modernize/cmd/modernize@latest -fix -test ./...` executed. `go generate ./...` ran afterwards to keep generated.
This commit is contained in:
@@ -40,13 +40,12 @@ func BenchmarkCrcHash(b *testing.B) {
|
||||
{1024},
|
||||
}
|
||||
for _, testCase := range cases {
|
||||
testCase := testCase
|
||||
key := randString(testCase.key)
|
||||
b.Run("", func(b *testing.B) {
|
||||
b.SetBytes(1024)
|
||||
b.ReportAllocs()
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
for b.Loop() {
|
||||
crcHashMod(key, 16)
|
||||
}
|
||||
})
|
||||
@@ -65,13 +64,12 @@ func BenchmarkSipHash(b *testing.B) {
|
||||
{1024},
|
||||
}
|
||||
for _, testCase := range cases {
|
||||
testCase := testCase
|
||||
key := randString(testCase.key)
|
||||
b.Run("", func(b *testing.B) {
|
||||
b.SetBytes(1024)
|
||||
b.ReportAllocs()
|
||||
b.ResetTimer()
|
||||
for i := 0; i < b.N; i++ {
|
||||
for b.Loop() {
|
||||
sipHashMod(key, 16, testUUID)
|
||||
}
|
||||
})
|
||||
@@ -164,7 +162,7 @@ func TestNewErasureSets(t *testing.T) {
|
||||
|
||||
nDisks := 16 // Maximum disks.
|
||||
var erasureDisks []string
|
||||
for i := 0; i < nDisks; i++ {
|
||||
for range nDisks {
|
||||
// Do not attempt to create this path, the test validates
|
||||
// so that newErasureSets initializes non existing paths
|
||||
// and successfully returns initialized object layer.
|
||||
|
||||
Reference in New Issue
Block a user