fix(testing): accidental shadowing in parallel tests (#18945)

pull/18944/head
George 2020-07-14 16:18:21 +01:00 committed by GitHub
parent cf52beb24e
commit a2c042c872
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 19 additions and 0 deletions

View File

@ -97,6 +97,7 @@ func AuthorizationService(
continue
}
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -115,6 +115,7 @@ func BucketService(
continue
}
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -207,6 +207,7 @@ func CheckService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -93,6 +93,7 @@ func DashboardService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -80,6 +80,7 @@ func DBRPMappingServiceV2(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -56,6 +56,7 @@ func KeyValueLog(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -76,6 +76,7 @@ func KVStore(
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -82,6 +82,7 @@ func LabelService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -75,6 +75,7 @@ func NotificationEndpointService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -72,6 +72,7 @@ func NotificationRuleStore(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -85,6 +85,7 @@ func OrganizationService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -39,6 +39,7 @@ func PasswordsService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -106,6 +106,7 @@ func ScraperService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -72,6 +72,7 @@ func SecretService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -77,6 +77,7 @@ func SessionService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -71,6 +71,7 @@ func TelegrafConfigStore(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -74,6 +74,7 @@ func UserResourceMappingService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -85,6 +85,7 @@ func UserService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})

View File

@ -78,6 +78,7 @@ func VariableService(
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tt := tt
t.Parallel()
tt.fn(init, t)
})