Skip to content

Commit

Permalink
golang format tools (knative#4769)
Browse files Browse the repository at this point in the history
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
/assign @mattmoor
  • Loading branch information
mattmoor-sockpuppet authored and knative-prow-robot committed Jul 17, 2019
1 parent bcd9277 commit a9061a1
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion test/conformance/api/v1alpha1/route_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ func TestRouteCreation(t *testing.T) {
defer test.TearDown(clients, names)

t.Log("Creating a new Route and Configuration")
config, err := v1a1test.CreateConfiguration(t, clients, names, )
config, err := v1a1test.CreateConfiguration(t, clients, names)
if err != nil {
t.Fatalf("Failed to create Configuration: %v", err)
}
Expand Down
6 changes: 3 additions & 3 deletions test/conformance/api/v1alpha1/service_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func TestRunLatestService(t *testing.T) {
test.CleanupOnInterrupt(func() { test.TearDown(clients, names) })

// Setup initial Service
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create initial Service %v: %v", names.Service, err)
}
Expand Down Expand Up @@ -265,7 +265,7 @@ func TestReleaseService(t *testing.T) {
)

// Setup initial Service
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create initial Service %v: %v", names.Service, err)
}
Expand Down Expand Up @@ -529,7 +529,7 @@ func TestAnnotationPropagation(t *testing.T) {
test.CleanupOnInterrupt(func() { test.TearDown(clients, names) })

// Setup initial Service
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
objects, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create initial Service %v: %v", names.Service, err)
}
Expand Down
4 changes: 2 additions & 2 deletions test/conformance/api/v1beta1/migration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func TestV1beta1Translation(t *testing.T) {
t.Log("Creating a new Service")
// Create a legacy RunLatest service. This should perform conversion during the webhook
// and return back a converted service resource.
service, err := v1a1test.CreateLatestServiceLegacy(t, clients, names, )
service, err := v1a1test.CreateLatestServiceLegacy(t, clients, names)
if err != nil {
t.Fatalf("Failed to create initial Service: %v: %v", names.Service, err)
}
Expand Down Expand Up @@ -84,7 +84,7 @@ func TestV1beta1Rejection(t *testing.T) {

t.Log("Creating a new Service")
// Create a legacy RunLatest service, but give it the TypeMeta of v1beta1.
service := v1a1test.LatestServiceLegacy(names, )
service := v1a1test.LatestServiceLegacy(names)
service.APIVersion = v1beta1.SchemeGroupVersion.String()
service.Kind = "Service"

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/helloworld_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func TestHelloWorld(t *testing.T) {
defer test.TearDown(clients, names)

t.Log("Creating a new Service")
resources, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
resources, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create initial Service: %v: %v", names.Service, err)
}
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/image_pull_error_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func TestImagePullError(t *testing.T) {
// Wrote our own thing so that we can pass in an image by digest.
// knative/pkg/test.ImagePath currently assumes there's a tag, which fails to parse.
func createLatestService(t *testing.T, clients *test.Clients, names test.ResourceNames) (*v1alpha1.Service, error) {
opt := v1alpha1testing.WithInlineConfigSpec(*v1a1test.ConfigurationSpec(names.Image, ))
opt := v1alpha1testing.WithInlineConfigSpec(*v1a1test.ConfigurationSpec(names.Image))
service := v1alpha1testing.ServiceWithoutNamespace(names.Service, opt)
v1a1test.LogResourceObject(t, v1a1test.ResourceObjects{Service: service})
return clients.ServingAlphaClient.Services.Create(service)
Expand Down
6 changes: 3 additions & 3 deletions test/e2e/namespace_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ func TestMultipleNamespace(t *testing.T) {
}
test.CleanupOnInterrupt(func() { test.TearDown(defaultClients, defaultResources) })
defer test.TearDown(defaultClients, defaultResources)
if _, err := v1a1test.CreateRunLatestServiceReady(t, defaultClients, &defaultResources, ); err != nil {
if _, err := v1a1test.CreateRunLatestServiceReady(t, defaultClients, &defaultResources); err != nil {
t.Fatalf("Failed to create Service %v in namespace %v: %v", defaultResources.Service, test.ServingNamespace, err)
}

Expand All @@ -73,7 +73,7 @@ func TestMultipleNamespace(t *testing.T) {
}
test.CleanupOnInterrupt(func() { test.TearDown(altClients, altResources) })
defer test.TearDown(altClients, altResources)
if _, err := v1a1test.CreateRunLatestServiceReady(t, altClients, &altResources, ); err != nil {
if _, err := v1a1test.CreateRunLatestServiceReady(t, altClients, &altResources); err != nil {
t.Fatalf("Failed to create Service %v in namespace %v: %v", altResources.Service, test.AlternativeServingNamespace, err)
}

Expand Down Expand Up @@ -125,7 +125,7 @@ func TestConflictingRouteService(t *testing.T) {

test.CleanupOnInterrupt(func() { test.TearDown(clients, names) })
defer test.TearDown(clients, names)
if _, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, ); err != nil {
if _, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names); err != nil {
t.Errorf("Failed to create Service %v in namespace %v: %v", names.Service, test.ServingNamespace, err)
}
}
2 changes: 1 addition & 1 deletion test/performance/benchmarks_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func runTest(t *testing.T, img string, baseQPS float64, loadFactors []float64) {
test.CleanupOnInterrupt(func() { TearDown(perfClients, names, t.Logf) })

t.Log("Creating a new Service")
objs, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
objs, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create Service: %v", err)
}
Expand Down
2 changes: 1 addition & 1 deletion test/performance/latency_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func timeToServe(t *testing.T, img, query string, reqTimeout time.Duration) {
test.CleanupOnInterrupt(func() { TearDown(perfClients, names, t.Logf) })

t.Log("Creating a new Service")
objs, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names, )
objs, err := v1a1test.CreateRunLatestServiceReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create Service: %v", err)
}
Expand Down
2 changes: 1 addition & 1 deletion test/upgrade/probe_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ func TestProbe(t *testing.T) {
}
defer test.TearDown(clients, names)

objects, err := v1a1test.CreateRunLatestServiceLegacyReady(t, clients, &names, )
objects, err := v1a1test.CreateRunLatestServiceLegacyReady(t, clients, &names)
if err != nil {
t.Fatalf("Failed to create Service: %v", err)
}
Expand Down

0 comments on commit a9061a1

Please sign in to comment.