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

Add UT for pkg/controllers/status/cluster_status_controller_test.go #3535

Merged

Conversation

realnumber666
Copy link
Contributor

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
Promote UT coverage

Which issue(s) this PR fixes:
Part of #3327

Does this PR introduce a user-facing change?:
NONE

@karmada-bot karmada-bot added the kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. label May 14, 2023
@karmada-bot karmada-bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label May 14, 2023
@codecov-commenter
Copy link

Codecov Report

Merging #3535 (ed1045f) into master (02f6a80) will increase coverage by 0.58%.
The diff coverage is n/a.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

@@            Coverage Diff             @@
##           master    #3535      +/-   ##
==========================================
+ Coverage   52.20%   52.79%   +0.58%     
==========================================
  Files         216      216              
  Lines       20012    20012              
==========================================
+ Hits        10447    10565     +118     
+ Misses       9001     8881     -120     
- Partials      564      566       +2     
Flag Coverage Δ
unittests 52.79% <ø> (+0.58%) ⬆️

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

see 2 files with indirect coverage changes

Copy link
Member

@zishen zishen left a comment

Choose a reason for hiding this comment

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

Good for controller test.

@realnumber666 realnumber666 changed the title Add UT for pkg/controllers/status/cluster_status_controller_test.go [WIP] Add UT for pkg/controllers/status/cluster_status_controller_test.go May 15, 2023
@karmada-bot karmada-bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 15, 2023
@realnumber666 realnumber666 force-pushed the add-ut/cluster_status_controller branch from ed1045f to f550863 Compare May 16, 2023 13:16
@karmada-bot karmada-bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 16, 2023
@realnumber666 realnumber666 changed the title [WIP] Add UT for pkg/controllers/status/cluster_status_controller_test.go Add UT for pkg/controllers/status/cluster_status_controller_test.go May 16, 2023
@karmada-bot karmada-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 16, 2023
@realnumber666 realnumber666 force-pushed the add-ut/cluster_status_controller branch 3 times, most recently from 8647728 to 05d596c Compare May 17, 2023 14:04
@XiShanYongYe-Chang
Copy link
Member

Thanks~
/assign

Copy link
Member

@XiShanYongYe-Chang XiShanYongYe-Chang left a comment

Choose a reason for hiding this comment

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

Good job!

pkg/controllers/status/cluster_status_controller_test.go Outdated Show resolved Hide resolved
pkg/controllers/status/cluster_status_controller_test.go Outdated Show resolved Hide resolved
pkg/controllers/status/cluster_status_controller_test.go Outdated Show resolved Hide resolved
@realnumber666 realnumber666 force-pushed the add-ut/cluster_status_controller branch from 05d596c to 66c2632 Compare May 18, 2023 07:41
@realnumber666 realnumber666 force-pushed the add-ut/cluster_status_controller branch from 66c2632 to 0c9b8d9 Compare May 18, 2023 08:12
Copy link
Member

@XiShanYongYe-Chang XiShanYongYe-Chang left a comment

Choose a reason for hiding this comment

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

/lgtm

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label May 18, 2023
Copy link
Member

@RainbowMango RainbowMango left a comment

Choose a reason for hiding this comment

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

/approve

@karmada-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: RainbowMango

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

@karmada-bot karmada-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 22, 2023
@karmada-bot karmada-bot merged commit 26b272a into karmada-io:master May 22, 2023
11 checks passed
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. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm Indicates that a PR is ready to be merged. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants