@@ -163,7 +163,6 @@ func TestServiceLifeCycle(t *testing.T) {
163163 stopped := make (map [string ]bool )
164164
165165 for id , maker := range services {
166- id := id // Closure for the constructor
167166 constructor := func (* ServiceContext ) (Service , error ) {
168167 return & InstrumentedService {
169168 startHook : func () { started [id ] = true },
@@ -263,7 +262,6 @@ func TestServiceConstructionAbortion(t *testing.T) {
263262 }
264263 started := make (map [string ]bool )
265264 for id , maker := range services {
266- id := id // Closure for the constructor
267265 constructor := func (* ServiceContext ) (Service , error ) {
268266 return & InstrumentedService {
269267 startHook : func () { started [id ] = true },
@@ -314,7 +312,6 @@ func TestServiceStartupAbortion(t *testing.T) {
314312 stopped := make (map [string ]bool )
315313
316314 for id , maker := range services {
317- id := id // Closure for the constructor
318315 constructor := func (* ServiceContext ) (Service , error ) {
319316 return & InstrumentedService {
320317 startHook : func () { started [id ] = true },
@@ -369,7 +366,6 @@ func TestServiceTerminationGuarantee(t *testing.T) {
369366 stopped := make (map [string ]bool )
370367
371368 for id , maker := range services {
372- id := id // Closure for the constructor
373369 constructor := func (* ServiceContext ) (Service , error ) {
374370 return & InstrumentedService {
375371 startHook : func () { started [id ] = true },
@@ -555,7 +551,6 @@ func TestAPIGather(t *testing.T) {
555551 }
556552
557553 for id , config := range services {
558- config := config
559554 constructor := func (* ServiceContext ) (Service , error ) {
560555 return & InstrumentedService {apis : config .APIs }, nil
561556 }
0 commit comments