[Umbrella] Enhance third-party resource interpreter tests with output verification
/kind cleanup
We wish to enhance the testing framework for third-party resource interpreter customizations by adding support for verifying Lua script execution results against expected outputs.
In addition, the current test coverage for Lua script content is insufficient. Each operation of each resource has only one test case, which is not enough to fully cover the logic. Therefore, we also need to supplement the test cases for individual operations of individual resources.
Below, let's list all the subtasks that need to be completed for the current work item.
- [x] enhance resource interpreter test framework @zhzhuang-zju #6938
- [ ] Complete test cases to cover the Lua script logic
- [ ] apps.kruise.io
- [ ] v1alpha1
- [x] AdvancedCronJob @XiShanYongYe-Chang #6991
- [ ] BroadcastJob
- [ ] CloneSet
- [ ] DaemonSet
- [ ] SidecarSet
- [ ] UnitedDeployment
- [ ] v1beta1 - StatefulSet
- [ ] v1alpha1
- [ ] argoproj.io - v1alpha1 - Workflow @yaten2302 #7012
- [ ] flink.apache.org - v1beta1 - FlinkDeployment
- [ ] helm.toolkit.fluxcd.io - v2beta1 - HelmRelease
- [ ] kubeflow.org - v1 - TFJob
- [ ] kustomize.toolkit.fluxcd.io - v1 - Kustomization
- [ ] kyverno.io - v1
- [ ] ClusterPolicy
- [ ] Policy
- [ ] source.toolkit.fluxcd.io
- [ ] v1 - GitRepository
- [ ] v1beta2
- [ ] Bucket
- [ ] HelmChart
- [ ] HelmRepository
- [ ] OCIRepository
- [ ] apps.kruise.io
If anyone is willing to get involved and complete some of these subtasks, we would be very grateful and welcome your participation.
You can directly tell me in the comments which subtasks you want to complete, and I will assign them to you.
/help
@XiShanYongYe-Chang: This request has been marked as needing help from a contributor.
Please ensure the request meets the requirements listed here.
If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-help command.
In response to this:
/help
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.
/good-first-issue
@XiShanYongYe-Chang: This request has been marked as suitable for new contributors.
Please ensure the request meets the requirements listed here.
If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-good-first-issue command.
In response to this:
/good-first-issue
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.
Hi @XiShanYongYe-Chang , I would like to work on the argoproj.io - v1alpha1 - Workflow one. Kindly assign that to me :)
Also, how can I verify these tests locally?
Hi @XiShanYongYe-Chang , I would like to work on the argoproj.io - v1alpha1 - Workflow one. Kindly assign that to me :)
Ok, thx~
Also, how can I verify these tests locally?
You can refer to https://github.com/karmada-io/karmada/blob/master/pkg/resourceinterpreter/default/thirdparty/README.md
Hi @XiShanYongYe-Chang , I've written and tested the ut for argoproj.io - v1alpha1 - Workflow, but, my this PR, I accidentally, created it from the main branch, and now I'm now the branch is ig 2 commits ahead and 20 behind the original branch of karmada.
Can I get a merge on that, so that I can raise a PR for this also :)
I'll take care of it from the next time on-wards!
Hi @yaten2302, you can create a new branch and rebase the karmada master branch:
git fetch <upstream repo name in your local site>
git checkout -b <your new branch> <upstream repo name in your local site>/master
And then you can cherry-pick your commit into your new branch and push it. After doing this, you can make a new pull request.
refer to https://karmada.io/docs/contributor/github-workflow
Raised the PR for the same, kindly review :) Thanks!
Hi @XiShanYongYe-Chang, I recently had my first PR merged (#7016). I’m still new to Kubernetes, but I’d like to learn by contributing. I’d like to pick "apps.kruise.io - CloneSet" from the subtasks here. Please let me know if that works. Thanks!
@Abhay349 Thanks, I assigned it to you.
Hi @XiShanYongYe-Chang, I’ve opened a small PR (#7019) that adds a test case for InterpretReplica of CloneSet, following the existing third-party customization patterns.Before proceeding with additional test cases or changes for CloneSet, I wanted to check if this direction looks good to you, or if you’d prefer a different approach.
Happy to iterate based on feedback. Thanks!
Hi @XiShanYongYe-Chang, I have learned a lot in my previous PR on CloneSet.. I'm planning to pick another item(likely BroadcastJob under apps.kruise.io) from same list... Please let me know if that sounds good or would you recommend a differnt next step...
Thanks!
@Abhay349 Thanks, I assigned BroadcastJob to you.