tests: migrate ctl_v3_kv_test.go to common testing framework#21333
tests: migrate ctl_v3_kv_test.go to common testing framework#21333veeceey wants to merge 4 commits intoetcd-io:mainfrom
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: veeceey The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @veeceey. 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. DetailsInstructions 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. |
8463187 to
1ceb0c2
Compare
|
/ok-to-test |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted filessee 23 files with indirect coverage changes @@ Coverage Diff @@
## main #21333 +/- ##
==========================================
+ Coverage 68.38% 68.46% +0.08%
==========================================
Files 428 428
Lines 35291 35291
==========================================
+ Hits 24132 24162 +30
+ Misses 9756 9734 -22
+ Partials 1403 1395 -8 Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
|
Hi, I noticed some CI checks haven't passed yet — I'm looking into whether they're related to my changes or are pre-existing/flaky. Will follow up once I have more details. In the meantime, would appreciate any feedback on the approach itself. Thanks! |
|
/retest |
1 similar comment
|
/retest |
Migrate PutIgnoreValue, PutIgnoreLease, Get (with rev, keys-only, count-only, min/max create/mod rev), and Delete tests from tests/e2e/ctl_v3_kv_test.go to the common testing framework in tests/common/kv_test.go, enabling them to run in both e2e and integration modes. Add IgnoreValue and IgnoreLease fields to config.PutOptions and implement support in both e2e (etcdctl) and integration client backends. Retain e2e-specific tests (GetFormat, GetRevokedCRL, PutClientTLSFlagByEnv) that depend on etcdctl output format or TLS-specific behavior. Fixes etcd-io#20550 Signed-off-by: Varun Chawla <varun_6april@hotmail.com>
Remove unused flags parameter from ctlV3Put since ignore-value and ignore-lease tests have been migrated to the common framework. Remove unused ctlV3LeaseRevoke function. Signed-off-by: Varun Chawla <varun_6april@hotmail.com>
Signed-off-by: Varun Chawla <varun_6april@hotmail.com>
After rebasing on main, the upstream TestCtlV3PutDialTimeout test uses context.DeadlineExceeded but the context package was not imported. Signed-off-by: Varun Chawla <varun_6april@hotmail.com>
a9e1266 to
113319e
Compare
|
hey, all CI checks are passing now. would appreciate a review when you get a chance - happy to address any feedback! |
|
Please squash commits |
| func TestCtlV3GetRev(t *testing.T) { testCtl(t, getRevTest) } | ||
| func TestCtlV3GetMinMaxCreateModRev(t *testing.T) { testCtl(t, getMinMaxCreateModRevTest) } | ||
| func TestCtlV3GetKeysOnly(t *testing.T) { testCtl(t, getKeysOnlyTest) } | ||
| func TestCtlV3GetCountOnly(t *testing.T) { testCtl(t, getCountOnlyTest) } |
Summary
PutIgnoreValue,PutIgnoreLease,Get(with rev, keys-only, count-only, min/max create/mod rev), andDeletetests fromtests/e2e/ctl_v3_kv_test.goto the common testing framework intests/common/kv_test.goIgnoreValueandIgnoreLeasefields toconfig.PutOptionsand implement support in both e2e (etcdctl) and integration client backendsGetFormat,GetRevokedCRL,PutClientTLSFlagByEnv) that depend on etcdctl output format or TLS-specific behaviorTest plan
TestKVPutIgnoreValuepasses with bothe2eandintegrationbuild tagsTestKVPutIgnoreLeasepasses with bothe2eandintegrationbuild tagsTestCtlV3GetFormat,TestCtlV3GetRevokedCRL,TestCtlV3PutClientTLSFlagByEnv) still passTestKVPut,TestKVGet,TestKVDelete) are unaffectedFixes #20550