|
1 | | -//go:build experimental |
2 | | -// +build experimental |
3 | | - |
4 | 1 | /* |
5 | 2 | Copyright 2023 The Kubernetes Authors. |
6 | 3 |
|
@@ -29,6 +26,7 @@ import ( |
29 | 26 |
|
30 | 27 | v1 "k8s.io/apimachinery/pkg/apis/meta/v1" |
31 | 28 | "k8s.io/apimachinery/pkg/util/sets" |
| 29 | + |
32 | 30 | "sigs.k8s.io/gateway-api/conformance" |
33 | 31 | confv1a1 "sigs.k8s.io/gateway-api/conformance/apis/v1alpha1" |
34 | 32 | "sigs.k8s.io/gateway-api/conformance/utils/config" |
@@ -196,7 +194,7 @@ func (suite *ExperimentalConformanceTestSuite) Run(t *testing.T, tests []Conform |
196 | 194 | suite.lock.Lock() |
197 | 195 | if suite.running { |
198 | 196 | suite.lock.Unlock() |
199 | | - return fmt.Errorf("can't run the test suite multiple times in parallel: the test suite is already running.") |
| 197 | + return fmt.Errorf("can't run the test suite multiple times in parallel: the test suite is already running") |
200 | 198 | } |
201 | 199 |
|
202 | 200 | // if the test suite is not currently running, reset reporting and start a |
@@ -251,11 +249,7 @@ func (suite *ExperimentalConformanceTestSuite) Report() (*confv1a1.ConformanceRe |
251 | 249 |
|
252 | 250 | profileReports := newReports() |
253 | 251 | for _, testResult := range suite.results { |
254 | | - conformanceProfiles, err := getConformanceProfilesForTest(testResult.test, suite.conformanceProfiles) |
255 | | - if err != nil { |
256 | | - return nil, err |
257 | | - } |
258 | | - |
| 252 | + conformanceProfiles := getConformanceProfilesForTest(testResult.test, suite.conformanceProfiles) |
259 | 253 | for _, profile := range conformanceProfiles.UnsortedList() { |
260 | 254 | profileReports.addTestResults(*profile, testResult) |
261 | 255 | } |
@@ -290,7 +284,7 @@ func ParseImplementation(org, project, url, version, contact string) (*confv1a1. |
290 | 284 | if version == "" { |
291 | 285 | return nil, errors.New("implementation's version can not be empty") |
292 | 286 | } |
293 | | - contacts := strings.SplitN(contact, ",", -1) |
| 287 | + contacts := strings.Split(contact, ",") |
294 | 288 | if len(contacts) == 0 { |
295 | 289 | return nil, errors.New("implementation's contact can not be empty") |
296 | 290 | } |
|
0 commit comments