Skip to content
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

chore: add chainsaw e2e tests support #3844

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

eddycharly
Copy link

Checklist:

  • Have you added an explanation of what your changes do and why you'd like them to be included?
  • Have you updated or added documentation for the change, as applicable?
  • Have you tested your changes on all related environments with successful results, as applicable?
    • Have you added automated tests?

Type of Changes:

  • New feature
  • Bug fix
  • Documentation
  • Testing enhancement
  • Other

What is the current behavior (link to any open issues here)?

Tests are run with kuttl

What is the new behavior (if this is a feature change)?

  • Breaking change (fix or feature that would cause existing functionality to change)

Tests are run with both chainsaw and kuttl

Other Information:

Chainsaw is similar to kuttl but a lot more flexible and actively maintained.

If you need more infos 👇

Signed-off-by: Charles-Edouard Brétéché <[email protected]>
@eddycharly
Copy link
Author

cc @jmckulk ;)

@jmckulk
Copy link
Collaborator

jmckulk commented Feb 8, 2024

Thanks for doing this! We have a story in our backlog to check out chainsaw and have added your pr to it!

Were you able to use the chainsaw migrate command? I know when I tried before it didn't like our scripts.

@eddycharly
Copy link
Author

eddycharly commented Feb 8, 2024

Yup, it was all done with chainsaw migrate kuttl tests ....

Only a few commands didn't pass (i fixed a bunch of bugs in v0.1.3 and a couple of other fixes will come in v0.1.4).

BTW would you mind approving the workflows to check how it works ?

pgDataVolume:
pvcName: data-non-crunchy-cluster-0
directory: data
postgresVersion: ${KUTTL_PG_VERSION}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The generate-kuttl Make target in the workflow is used to fill out these variables with certain variables that might be different between tests. We would need to update/duplicate that target for chainsaw or figure out a different way to use variables.

@eddycharly Does chainsaw have a concept of variables or variable expansion?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

v0.1.3 introduced support to pass arbitrary values to tests and v0.1.4 will come with a solution to inject values in the resource manifests so basically no need for a generate step anymore :)

Signed-off-by: Charles-Edouard Brétéché <[email protected]>
Signed-off-by: Charles-Edouard Brétéché <[email protected]>
Signed-off-by: Charles-Edouard Brétéché <[email protected]>
Signed-off-by: Charles-Edouard Brétéché <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants