Skip to content

bug: OpenShift source Plan Archive fixture fails during cloning #691

Description

@myakove

Summary

The prepared_plan fixture fails for OpenShift source-provider runs of TestPlanArchivePvcCleanup before the test can execute.

Problem / Motivation

For ProviderType.OPENSHIFT, conftest.py creates the source VM through create_source_cnv_vms (approximately lines 1143–1165). Later, the generic if not skip_clone path calls clone_provider.get_vm_by_name (approximately line 1267). OCPProvider in libs/providers/openshift.py does not implement get_vm_by_name, so the class fixture fails before the Plan Archive PVC cleanup test starts. This was uncovered during the docstring review for PR #624: #624

Reproduction

On a properly configured cluster with an OpenShift source provider, run the plan_lifecycle test for TestPlanArchivePvcCleanup using that source provider. The prepared_plan class fixture creates the source VM, then reaches the generic clone lookup and fails because OCPProvider has no get_vm_by_name method.

Expected / Actual

  • Expected: The test uses the source VM already created by create_source_cnv_vms and proceeds to the Plan Archive PVC cleanup scenario.
  • Actual: Fixture setup fails in the generic cloning path before any test method runs.

Requirements

  1. For OpenShift source-provider runs, reuse the VM created by create_source_cnv_vms and skip cloning it.
  2. Keep the change scoped to the OpenShift source fixture flow; do not alter generic provider cloning paths.

Deliverables

  • Fix the OpenShift source fixture flow
  • Verify the TestPlanArchivePvcCleanup reproduction on a properly configured cluster

Assisted-by: PI (${PI_MODEL:-unknown})

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions