Skip to content

Commit

Permalink
rework managed service validation
Browse files Browse the repository at this point in the history
Signed-off-by: Artem Bortnikov <[email protected]>
  • Loading branch information
BROngineer committed Jan 20, 2025
1 parent 9a8bfd0 commit e4df9c0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion test/e2e/clusterdeployment/servicevalidator.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func (v *ServiceValidator) Validate(ctx context.Context, kc *kubeclient.KubeClie
clusterKubeClient := kc.NewFromCluster(ctx, v.namespace, v.clusterDeploymentName)

for resourceName, resource := range v.resourcesToValidate {
resourceFullName := resource.resourceFullName(v.managedServiceName)
resourceFullName := fmt.Sprintf("%s-%s", resource.resourceFullName(v.managedServiceName), "controller")
err := resource.ValidationFunc(ctx, clusterKubeClient, resourceFullName)
if err != nil {
_, _ = fmt.Fprintf(GinkgoWriter, "[%s/%s] validation error: %v\n", v.template, resourceName, err)
Expand Down
4 changes: 2 additions & 2 deletions test/e2e/multi_provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ var _ = Context("Multi Cloud Templates", Label("provider:cloud", "provider:aws-a
})
Eventually(func() error {
return awsServiceDeployedValidator.Validate(context.Background(), kc)
}).WithTimeout(30 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())
}).WithTimeout(10 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())

azureServiceDeployedValidator := clusterdeployment.NewServiceValidator(azureClusterDeploymentName, "default", "managed-ingress-nginx").
WithResourceValidation("service", clusterdeployment.ManagedServiceResource{
Expand All @@ -209,7 +209,7 @@ var _ = Context("Multi Cloud Templates", Label("provider:cloud", "provider:aws-a
})
Eventually(func() error {
return azureServiceDeployedValidator.Validate(context.Background(), kc)
}).WithTimeout(30 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())
}).WithTimeout(10 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())
})
})
})
2 changes: 1 addition & 1 deletion test/e2e/provider_aws_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ var _ = Describe("AWS Templates", Label("provider:cloud", "provider:aws"), Order
})
Eventually(func() error {
return serviceDeployedValidator.Validate(context.Background(), kc)
}).WithTimeout(30 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())
}).WithTimeout(10 * time.Minute).WithPolling(10 * time.Second).Should(Succeed())

templateBy(clusterdeployment.TemplateAWSHostedCP, "installing controller and templates on standalone cluster")

Expand Down

0 comments on commit e4df9c0

Please sign in to comment.