Skip to content

Add E2E conformance test for BroadcastJob uncordon handling #2090

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

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

GautamBytes
Copy link

Ⅰ. Describe what this PR does

This change enhances the existing BroadcastJob end‑to‑end test suite by adding a new conformance test that verifies the controller correctly recreates pods when a cordoned node is subsequently uncordoned.

  • Imports types.StrategicMergePatchType for patch operations.
  • Adds a KruiseDescribe/ConformanceIt block named "BroadcastJob uncordon handling".
  • Creates a fake node, cordons it, launches a BroadcastJob, then uncordons and asserts the missing pod is eventually created.
  • Uses exit 0 in the container command to avoid manual status‐patch races.
  • Defers cleanup of both fake node and BroadcastJob resource.

Ⅱ. Does this pull request fix one issue?

fixes #1233

Ⅲ. Describe how to verify it

  1. Ensure you have a Kubernetes cluster available for testing.

  2. Check out this branch and run the full E2E suite:

    go test ./test/e2e/... -timeout=20m
  3. Confirm that all tests, including the new BroadcastJob uncordon handling conformance test, pass successfully.

Ⅳ. Special notes for reviews

Check out this branch and run the full E2E suite:

go test ./test/e2e/... -timeout=20m

Signed-off-by: GautamBytes <[email protected]>
@kruise-bot kruise-bot requested review from Fei-Guo and veophi June 27, 2025 11:36
@kruise-bot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign fillzpp for approval by writing /assign @fillzpp in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found 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

@kruise-bot
Copy link

Welcome @GautamBytes! It looks like this is your first PR to openkruise/kruise 🎉

@kruise-bot kruise-bot added the size/M size/M: 30-99 label Jun 27, 2025
Copy link

codecov bot commented Jun 27, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 43.97%. Comparing base (4778e7c) to head (ca07514).
Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2090      +/-   ##
==========================================
- Coverage   43.98%   43.97%   -0.01%     
==========================================
  Files         316      316              
  Lines       31776    31844      +68     
==========================================
+ Hits        13976    14003      +27     
- Misses      16392    16429      +37     
- Partials     1408     1412       +4     
Flag Coverage Δ
unittests 43.97% <ø> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/M size/M: 30-99
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feature request] Add e2e for broadcastjob
2 participants