Remove unnecessary copies of loop variables (#28138)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
b6bd92f90e
Коммит
d9e47522a0
@@ -204,7 +204,6 @@ func TestCommandResponseFromJSON(t *testing.T) {
|
||||
}
|
||||
|
||||
for _, testCase := range testCases {
|
||||
testCase := testCase
|
||||
t.Run(testCase.Description, func(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
|
||||
@@ -963,7 +963,6 @@ func TestNowhereNil(t *testing.T) {
|
||||
}
|
||||
|
||||
for _, testCase := range testCases {
|
||||
testCase := testCase
|
||||
t.Run(testCase.Description, func(t *testing.T) {
|
||||
defer func() {
|
||||
if r := recover(); r != nil {
|
||||
@@ -1196,7 +1195,6 @@ func TestIsValidHTTPURL(t *testing.T) {
|
||||
}
|
||||
|
||||
for _, testCase := range testCases {
|
||||
testCase := testCase
|
||||
t.Run(testCase.Description, func(t *testing.T) {
|
||||
defer func() {
|
||||
if r := recover(); r != nil {
|
||||
|
||||
Ссылка в новой задаче
Block a user