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

ci: fix flaky test for stale instance type drift #1990

Conversation

flavono123
Copy link
Contributor

@flavono123 flavono123 commented Feb 14, 2025

Fixes #1986

Description

  1. change Offering.Requirements of InstanceType over Requirements for setup test; ofs.HasCompatible compare Offering.Requirements with the argument(NodeClaim.Labels in this case) -> so i don't know how the test was passed sometimes
  2. fix the key for changing value to Offering.Requirements concerns since a return of lo.Keys is not sorted, the previous key was random.
    a. just one changing is enough so commented another

chore: remove trailing whitespaces in Makefile

How was this change tested?

check the test case is passed on make deflake FOCUS="should detect stale instance type drift if the instance type offerings aren't compatible with the nodeclaim"

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Feb 14, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @flavono123. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Feb 14, 2025
@flavono123 flavono123 force-pushed the fix/flaky-test-drift-for-stale-instance-type branch from 18b04e2 to fb88566 Compare February 14, 2025 09:54
@coveralls
Copy link

coveralls commented Feb 14, 2025

Pull Request Test Coverage Report for Build 13352013025

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 8 unchanged lines in 3 files lost coverage.
  • Overall coverage decreased (-0.04%) to 81.439%

Files with Coverage Reduction New Missed Lines %
pkg/controllers/node/termination/controller.go 2 71.65%
pkg/test/expectations/expectations.go 2 94.81%
pkg/controllers/disruption/consolidation.go 4 88.55%
Totals Coverage Status
Change from base Build 13342929537: -0.04%
Covered Lines: 9245
Relevant Lines: 11352

💛 - Coveralls

@jonathan-innis
Copy link
Member

@flavono123 Thanks for picking this one up!

@flavono123 flavono123 force-pushed the fix/flaky-test-drift-for-stale-instance-type branch from b2220e1 to 00a5daa Compare February 16, 2025 05:15
Copy link
Member

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 16, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: flavono123, jonathan-innis

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 16, 2025
@k8s-ci-robot k8s-ci-robot merged commit 2b05d96 into kubernetes-sigs:main Feb 16, 2025
13 checks passed
@flavono123 flavono123 deleted the fix/flaky-test-drift-for-stale-instance-type branch February 16, 2025 23:03
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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Drift Test is Flaking
4 participants