More idioms related to go 1.26

This commit is contained in:
9seconds
2026-02-17 23:38:12 +01:00
parent 80b9159ce9
commit 3b03c4a90a
21 changed files with 33 additions and 33 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ func (suite *CircuitBreakerTestSuite) TestMultipleRunsOk() {
suite.ctxCancel()
}()
for i := 0; i < 5; i++ {
for range 5 {
go func() {
defer wg.Done()
+1 -1
View File
@@ -64,7 +64,7 @@ func (suite *LoadBalancedSocks5TestSuite) TestCannotDial() {
})
suite.NoError(err)
for i := 0; i < network.ProxyDialerOpenThreshold*2; i++ {
for range network.ProxyDialerOpenThreshold * 2 {
_, err = lbDialer.Dial("tcp", "127.1.1.1:80")
suite.True(errors.Is(err, network.ErrCannotDialWithAllProxies))
}