-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Start migrating e2e tests to Go. #3079
Conversation
Sorry for the delay here, but here's a sample PR with E2E tests in Go. I have also added sample logs from a test run to see how they look. I feel that the logs are a lot cleaner as well compared to the ones from |
I'm a bit busy atm, but I'll review it ASAP, huge kudos for this improvement! ❤️ ❤️ ❤️ ❤️ |
That would be great. If the sample looks okay, I will start working on migrating all the other Azure scalers as a part of this PR as well. After that the community can start working on others, and help with the migration. |
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.
Looking good! Great job :)
We should find a way how to run these in parallel until the full migration is done.
Could you please also update the https://github.com/kedacore/keda/blob/main/tests/README.md in this PR as well? |
Could you explain what you mean by this? The run-all.sh file does run the tests in parallel, right? Or do you mean running the |
yeah, but it's more a matter of modifying GH Workflows. @JorTurFer might have better idea. Let's solve this once this PR is ready. |
Currently, I kept these tests under a folder After the complete migration, we can remove the contents of And yes, I will add a readme to |
sounds like a good plan! |
The only concern I have is running both the workflows will increase time required. I think what might be a good approach is, letting the main build that gets run on a PR merge not be changed until complete migration is done. And, for PRs have a temporary separate command such as |
uff... Adding a second command could be a pain TBH. The command is a super custom workload that I did, and duplicate it could be horrible. Maybe we can just run both all the time due to we are going to move the tests from one to another, so once we have moved the test to Golang, it shouldn't exist for a long time in typescript. |
One more thing, the command |
I would go the simplest way - execute both test suites and always delete overlapping tests. |
Agree. The best part of this is that |
I am keeping the Replaced the I have also added a section in the README with some instructions and a small example. It isn't the best, but I will try to improve it in the future. |
I will be adding these tests as a part of this PR (hopefully by Monday/Tuesday).
And hopefully once this PR is merged, the community steps up in helping with the migration and takes up the other scalers. |
The |
@v-shenoy do you think that you can add only a subset of these tests in this PR? There are some new scalers that could already use the golang version. You can add the rest of the Azure related tests in a subsequent PR. WDYT? |
Please do that in this PR (also include |
Alright, I can add the Service Bus (Queue + Topic + Workload) and Key Vault tests. And then add the rest later. Does that seem good? |
@v-shenoy yeah, thanks 🙏 |
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
/run-e2e |
I only just remembered I could also run tests, haha. Well, it works, and is going to be really helpful :D |
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
/run-e2e |
I think that this problem is solved with this deletion "just in case" at the end of every e2e process 😄 |
I have to recognize that I love the improvement in the loging, I mean, something as simple as like |
I'm thinking on what will happen in case of panic, and I'm not sure if we will face with stuck namespaces 🤔 |
The tests are passing, whew! |
I am not sure if |
I was talking about doing something like this while read -r namespace
do
kubectl delete $(kubectl get scaledobjects,scaledjobs -oname -n "$namespace") -n "$namespace"
done < (kubectl get namespaces) Doing this as part of the |
Yup, I was thinking something exactly like this. |
Don't forget to include TriggerAuth... :) And then finally namespaces. |
TriggerAuth doesn't have finalizers, so I think that we can just delete them deleting the CRD, the problems are the resources with finalizers :/ |
The namespaces get deleted with |
Signed-off-by: Vighnesh Shenoy <vshenoy@microsoft.com>
/run-e2e |
@JorTurFer @zroubalik I have added a The tests also seem to be running fine. Any more changes expected in this PR? |
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!
Thanks for this incredible improvement ❤️
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, awesome stuff! 🚀
Signed-off-by: Vighnesh Shenoy vshenoy@microsoft.com
Provide a description of what has been changed
Start migrating e2e tests to Go for code parity.
Sample Logs
Checklist
Relates to #2737