Skip to content

Commit f5d4a1d

Browse files
committed
[lint] fix more issues
1 parent c902c35 commit f5d4a1d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

pkg/cache/memory_bench_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ func BenchmarkMemoryCache_RandomAccess(b *testing.B) {
408408
const numKeys = 1000
409409

410410
// Pre-populate cache with many keys
411-
for i := 0; i < numKeys; i++ {
411+
for i := range numKeys {
412412
key := "key-" + strconv.Itoa(i)
413413
value := "value-" + strconv.Itoa(i)
414414
cache.Set(ctx, key, []byte(value))

pkg/cache/memory_concurrency_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ func TestMemoryCache_RaceConditionDetection(_ *testing.T) {
409409

410410
start := time.Now()
411411

412-
for i := 0; i < numGoroutines; i++ {
412+
for i := range numGoroutines {
413413
wg.Add(1)
414414
go func(goroutineID int) {
415415
defer wg.Done()

0 commit comments

Comments
 (0)