Skip to content

Commit

Permalink
Avoid DPA cleanup error on virt-only AfterSuite. (#1325)
Browse files Browse the repository at this point in the history
The E2E AfterSuite fails if no DPA has been created, because
v.CustomResource has all empty fields. The virtualization tests do not
create a DPA yet, so add interim dummy values to avoid the error in CI.

Signed-off-by: Matthew Arnold <marnold@redhat.com>
  • Loading branch information
mrnold committed Feb 9, 2024
1 parent 314cb26 commit 20ee343
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/e2e/virt_backup_restore_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ var _ = Describe("VM backup and restore tests", Ordered, func() {
wasInstalledFromTest := false

var _ = BeforeAll(func() {
dpaCR.CustomResource.Name = "dummyDPA"
dpaCR.CustomResource.Namespace = "openshift-adp"

v, err = GetVirtOperator(runTimeClientForSuiteRun, kubernetesClientForSuiteRun, dynamicClientForSuiteRun)
Expect(err).To(BeNil())
Expect(v).ToNot(BeNil())
Expand Down

0 comments on commit 20ee343

Please sign in to comment.