-
Notifications
You must be signed in to change notification settings - Fork 1
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
PipelineRollout Tests #41
Conversation
ae0dbe8
to
3fb019e
Compare
By("bootstrapping test environment") | ||
// TODO: IDEA: could set useExistingCluster via an env var to be able to reuse some tests cases in e2e tests | ||
// by setting this variable in CI for unit tests and e2e tests appropriately. |
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.
what does it mean "to reuse some test cases in e2e tests"? do you have an example of what you mean?
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.
The test cases in the pipelinerollout_controller_test.go
file test PipelineRollout lifecycle (create, update, delete operations). These could be reused in e2e tests and, when using a real/preexisting cluster, also the deletion of the Numaflow Pipeline on deletion of PipelineRollout could be tested (https://github.com/numaproj/numaplane/pull/41/files#diff-31f7e2289e4cc3f50a723cc05922642d3cc20247ed71f66dc7dab1a73d3f302cR237-R245).
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.
Interesting. Possibly. Although, that will likely use the same test framework "github.com/stretchr/testify/suite" we were previously using....so you'd have to see if it would be easily callable from there, or otherwise may not be worth it
This is very elegant....but I'm not sure if I see any cases of things going wrong? should that be added to a subsequent PR? (at least the case of invalid yaml, not sure what else off the top of my head) |
It should be noted this unit test doesn't really cover things on an individual function level, but maybe this is really the only good way to test |
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]>
@juliev0 do you want to take another look? Otherwise I will merge this. Thanks! |
please do, thanks! |
Signed-off-by: Antonino Fugazzotto <[email protected]> Signed-off-by: dsimha <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]> Signed-off-by: dsimha <[email protected]>
Signed-off-by: Antonino Fugazzotto <[email protected]> Signed-off-by: dsimha <[email protected]>
Fixes #20
Modifications
Updated the
suite_test.go
file to be able to setup an environment to test PipelineRollout reconciliation logic using Numaflow CRDs. Also, added test cases topipelinerollout_controller_test.go
file to test create, update, and delete of a PipelineRollout resource.Verification
Issued
make test
command and verify all tests passed.