-
Notifications
You must be signed in to change notification settings - Fork 9.8k
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: use require.NoError instead of t.Fatal(err) in tests and tools packages #18709
Conversation
Hi @mmorel-35. Thanks for your PR. I'm waiting for a etcd-io member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the 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. |
/assign @wenjiaswe |
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted filessee 22 files with indirect coverage changes @@ Coverage Diff @@
## main #18709 +/- ##
==========================================
+ Coverage 68.72% 68.75% +0.02%
==========================================
Files 420 420
Lines 35494 35494
==========================================
+ Hits 24395 24404 +9
+ Misses 9665 9661 -4
+ Partials 1434 1429 -5 Continue to review full report in Codecov by Sentry.
|
/ok-to-test |
Hi @mmorel-35, PTAL at the prow job pull-etcd-verify failure: https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/etcd-io_etcd/18709/pull-etcd-verify/1844226305705381888#1:build-log.txt%3A841 |
3165153
to
3840876
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with a minor comment
Thanks
tests/common/alarm_test.go
Outdated
if err := cc.Put(ctx, "1st_test", smallbuf, config.PutOptions{}); err != nil { | ||
t.Fatalf("alarmTest: put kv error (%v)", err) | ||
} | ||
require.NoErrorf(t, cc.Put(ctx, "1st_test", smallbuf, config.PutOptions{}), "alarmTest: put kv error") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor comment
require.NoErrorf(t, cc.Put(ctx, "1st_test", smallbuf, config.PutOptions{}), "alarmTest: put kv error") | |
err := cc.Put(ctx, "1st_test", smallbuf, config.PutOptions{}) | |
require.NoErrorf(t, err, "alarmTest: put kv error") |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ahrtr, mmorel-35 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 |
…ackages Signed-off-by: Matthieu MOREL <[email protected]>
3840876
to
5dabe45
Compare
@mmorel-35: The following tests failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. 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. I understand the commands that are listed here. |
Oops, approved the wrong PR. |
I screw something with my commits. |
/retest duh nevermind |
There is no linter for this.
This uses testify instead of testing for
With
instead of
This is only a part of this packages. I'll provide other PRs for the rest of it.