From 58eb3710fc2ad11af19c7e927f8adbad81e63071 Mon Sep 17 00:00:00 2001 From: Chris Piraino Date: Tue, 23 Jun 2020 13:48:30 -0400 Subject: [PATCH] remove obsolete comments about test parallelization --- agent/structs/config_entry_gateways_test.go | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/agent/structs/config_entry_gateways_test.go b/agent/structs/config_entry_gateways_test.go index 68cc2cf5f..e86d23302 100644 --- a/agent/structs/config_entry_gateways_test.go +++ b/agent/structs/config_entry_gateways_test.go @@ -77,10 +77,7 @@ func TestIngressConfigEntry_Normalize(t *testing.T) { }, } - for _, test := range cases { - // We explicitly copy the variable for the range statement so that can run - // tests in parallel. - tc := test + for _, tc := range cases { t.Run(tc.name, func(t *testing.T) { err := tc.entry.Normalize() require.NoError(t, err) @@ -436,10 +433,7 @@ func TestIngressConfigEntry_Validate(t *testing.T) { }, } - for _, test := range cases { - // We explicitly copy the variable for the range statement so that can run - // tests in parallel. - tc := test + for _, tc := range cases { t.Run(tc.name, func(t *testing.T) { err := tc.entry.Validate() if tc.expectErr != "" { @@ -546,10 +540,7 @@ func TestTerminatingConfigEntry_Validate(t *testing.T) { }, } - for _, test := range cases { - // We explicitly copy the variable for the range statement so that can run - // tests in parallel. - tc := test + for _, tc := range cases { t.Run(tc.name, func(t *testing.T) { err := tc.entry.Validate() @@ -610,10 +601,7 @@ func TestGatewayService_Addresses(t *testing.T) { }, } - for _, test := range cases { - // We explicitly copy the variable for the range statement so that can run - // tests in parallel. - tc := test + for _, tc := range cases { t.Run(tc.name, func(t *testing.T) { addresses := tc.input.Addresses(tc.argument) require.ElementsMatch(t, tc.expected, addresses)