Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

e2e testing for CAPI with CAPO #280

Merged
merged 2 commits into from
Dec 12, 2023

Conversation

EmilienM
Copy link
Member

  • Add cluster-capi-operator integration
  • vendoring: add cluster-capi-operator && go mod vendor

@EmilienM EmilienM force-pushed the capi_osp_e2e branch 3 times, most recently from 369122c to 344a698 Compare November 23, 2023 16:51
@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 29, 2023
@openshift-merge-robot openshift-merge-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 30, 2023
@stephenfin stephenfin force-pushed the capi_osp_e2e branch 2 times, most recently from 041cfb5 to 6abc212 Compare November 30, 2023 18:52
These are heavily based on the tests for other platforms, which are
currently included in the cluster-capi-operator tree [1] but which will
eventually be moved out to the openshift forks of the respective CAPI
implementations. The key difference from these is that (a) we don't
create a cluster (since we have the infracluster controller for this)
and (b) we obviously use OpenStack-specific semantics.

[1] https://github.com/openshift/cluster-capi-operator/tree/release-4.15/e2e

Co-Authored-By: Emilien Macchi <emilien@redhat.com>
Co-Authored-By: Stephen Finucane <stephenfin@redhat.com>
@stephenfin
Copy link

/test e2e-techpreview

@EmilienM
Copy link
Member Author

EmilienM commented Dec 4, 2023

@stephenfin I think something is failing on purpose, due to the fact the job is TechPreview:

ClusterOperators:
	clusteroperator/config-operator is not upgradeable because FeatureGatesUpgradeable: "TechPreviewNoUpgrade" does not allow updates

i'll investigate that

@EmilienM
Copy link
Member Author

EmilienM commented Dec 4, 2023

In fact I think the error is really:

	clusteroperator/machine-config is not available (Cluster not available for [{operator 4.15.0-0.ci.test-2023-12-04-171123-ci-op-flixkrw1-latest}]: failed to apply machine config controller manifests: Get "https://172.30.0.1:443/apis/rbac.authorization.k8s.io/v1/clusterroles/machine-config-controller": http2: client connection lost) because Failed to resync 4.15.0-0.ci.test-2023-12-04-171123-ci-op-flixkrw1-latest because: failed to apply machine config controller manifests: Get "https://172.30.0.1:443/apis/rbac.authorization.k8s.io/v1/clusterroles/machine-config-controller": http2: client connection lost

@EmilienM
Copy link
Member Author

EmilienM commented Dec 4, 2023

/test e2e-techpreview

@EmilienM
Copy link
Member Author

EmilienM commented Dec 4, 2023

/lgtm
/approve

Copy link

openshift-ci bot commented Dec 4, 2023

@EmilienM: you cannot LGTM your own PR.

In response to this:

/lgtm
/approve

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Copy link

openshift-ci bot commented Dec 4, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: EmilienM

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 4, 2023
k8s.io/api v0.28.2
k8s.io/apimachinery v0.28.2
k8s.io/client-go v0.28.1
sigs.k8s.io/cluster-api v1.5.2
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes me slightly nervous, because it highlights a diamond dependency that we have.

i.e. CAPO depends on CAPI version X. cluster-capi-operator depends on CAPI version Y. If CAPO depends on cluster-capi-operator, what happens when X and Y are not reconcilable?

Would it be feasible to define the e2e tests in their own go module and remove all dependencies on CAPO/openshift? It took a quick look, and I think the e2e tests may only be importing some constants? If we duplicated those constants in the test, which may not be a bad idea anyway, can we eliminate the dependency?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, it looks like we're only using the constants so I can drop those.

@stephenfin
Copy link

I'm going to approve this as-is. The diamond dependency is real, but we can address with a refactor when it comes up as an issue.

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Dec 12, 2023
@stephenfin
Copy link

/test e2e-techpreview

Actual test passed. Failure came later during the gather.

Copy link

openshift-ci bot commented Dec 12, 2023

@EmilienM: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@openshift-merge-bot openshift-merge-bot bot merged commit db44aa6 into openshift:main Dec 12, 2023
6 checks passed
@openshift-bot
Copy link

[ART PR BUILD NOTIFIER]

This PR has been included in build openstack-cluster-api-controllers-container-v4.16.0-202312130634.p0.gdb44aa6.assembly.stream for distgit openstack-cluster-api-controllers.
All builds following this will include this PR.

@stephenfin stephenfin deleted the capi_osp_e2e branch December 14, 2023 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants