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

fix(test): makes DSCI-dependent tests self-contained #1235

Merged

Conversation

bartoszmajsak
Copy link
Contributor

@bartoszmajsak bartoszmajsak commented Sep 13, 2024

Description

Ensures each test uses a different DSCI instance as a test fixture. Without this change, tests are failing (as they do in the latest incubation commit). The reason is #1222 that introduced a validation check to ensure AppNamespace is immutable, but #1228 is trying to update DSCI violating the new constraint. The issue is that #1228 was merged first and only then #1222 came in, but without being first rebased on top of incubation.

With this change, each test uses a dedicated DSCI.

Important

This issue was not caught earlier for two reasons:

  • PRs are not enforced to be up-to-date with latest state of incubation before merged.
  • Pushes to incubation do not trigger test jobs.

With this we ended up with #1228 merged first and #1222 being behind was merged afterwards without triggering the jobs. In conjunction, it results in failing make test against latest incubation.
Ideally we should ensure both mentioned weaknesses are addressed.

How Has This Been Tested?

Screenshot or short clip

Merge criteria

  • You have read the contributors guide.
  • Commit messages are meaningful - have a clear and concise summary and detailed explanation of what was changed and why.
  • Pull Request contains a description of the solution, a link to the JIRA issue, and to any dependent or related Pull Request.
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has manually tested the changes and verified that the changes work

Ensures each tests uses different DSCI instance as a test fixture.
Without this tests are failing (as they do in latest incubation commit),
as opendatahub-io#1222 introduced validation check to ensure AppNamespace is
immutable, but opendatahub-io#1228 is trying to update DSCI violating new constraint.

With this change each test uses dedicated DSCI.
Copy link

openshift-ci bot commented Sep 14, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: zdtsw

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-merge-bot openshift-merge-bot bot merged commit df1add0 into opendatahub-io:incubation Sep 14, 2024
8 checks passed
bartoszmajsak added a commit to bartoszmajsak/opendatahub-operator that referenced this pull request Sep 14, 2024
Unit tests job is currently only executed on PRs, leaving pushes on e.g.
incubation branch untested. This can lead to issues like the one
described in opendatahub-io#1235

This PR enables GH Action to be run also for push events.
@bartoszmajsak bartoszmajsak deleted the fix-dsci-tests branch September 14, 2024 13:54
VaishnaviHire pushed a commit to VaishnaviHire/opendatahub-operator that referenced this pull request Sep 16, 2024
…1235)

Ensures each tests uses different DSCI instance as a test fixture.
Without this tests are failing (as they do in latest incubation commit),
as opendatahub-io#1222 introduced validation check to ensure AppNamespace is
immutable, but opendatahub-io#1228 is trying to update DSCI violating new constraint.

With this change each test uses dedicated DSCI.

(cherry picked from commit df1add0)
VaishnaviHire pushed a commit to VaishnaviHire/opendatahub-operator that referenced this pull request Sep 16, 2024
…1235)

Ensures each tests uses different DSCI instance as a test fixture.
Without this tests are failing (as they do in latest incubation commit),
as opendatahub-io#1222 introduced validation check to ensure AppNamespace is
immutable, but opendatahub-io#1228 is trying to update DSCI violating new constraint.

With this change each test uses dedicated DSCI.

(cherry picked from commit df1add0)
openshift-merge-bot bot referenced this pull request in red-hat-data-services/rhods-operator Sep 18, 2024
Ensures each tests uses different DSCI instance as a test fixture.
Without this tests are failing (as they do in latest incubation commit),
as #1222 introduced validation check to ensure AppNamespace is
immutable, but #1228 is trying to update DSCI violating new constraint.

With this change each test uses dedicated DSCI.

(cherry picked from commit df1add0)
openshift-merge-bot bot pushed a commit that referenced this pull request Sep 19, 2024
* ci: ensures tests are run on push

Unit tests job is currently only executed on PRs, leaving pushes on e.g.
incubation branch untested. This can lead to issues like the one
described in #1235

This PR enables GH Action to be run also for push events.

* ci: limit branches for push events

Co-authored-by: Wen Zhou <wenzhou@redhat.com>

* fix(gh-action): correct use of pull_request element

adds missing trailing colon

---------

Co-authored-by: Wen Zhou <wenzhou@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants