Skip to content

Commit

Permalink
Minor changes to test assertions
Browse files Browse the repository at this point in the history
  • Loading branch information
wahabmk committed Nov 6, 2024
1 parent a2ee854 commit 39faf3a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion internal/controller/multiclusterservice_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,8 @@ var _ = Describe("MultiClusterService Controller", func() {

By("having the valid service template status")
Expect(k8sClient.Get(ctx, serviceTemplateRef, serviceTemplate)).To(Succeed())
Expect(serviceTemplate.Status.Valid && serviceTemplate.Status.ValidationError == "").To(BeTrue())
Expect(serviceTemplate.Status.Valid).To(BeTrue())
Expect(serviceTemplate.Status.ValidationError).To(BeEmpty())

By("creating MultiClusterService")
err = k8sClient.Get(ctx, multiClusterServiceRef, multiClusterService)
Expand Down
3 changes: 2 additions & 1 deletion internal/controller/template_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,8 @@ var _ = Describe("Template Controller", func() {

By("Having the valid cluster template status")
Expect(k8sClient.Get(ctx, client.ObjectKeyFromObject(clusterTemplate), clusterTemplate)).To(Succeed())
Expect(clusterTemplate.Status.Valid && clusterTemplate.Status.ValidationError == "").To(BeTrue())
Expect(clusterTemplate.Status.Valid).To(BeTrue())
Expect(clusterTemplate.Status.ValidationError).To(BeEmpty())
Expect(clusterTemplate.Status.Providers).To(HaveLen(2))
Expect(clusterTemplate.Status.ProviderContracts).To(HaveLen(2))
Expect(clusterTemplate.Status.Providers[0]).To(Equal(someProviderName))
Expand Down

0 comments on commit 39faf3a

Please sign in to comment.