charmed-kubernetes / pytest-operator

Apache License 2.0
7 stars 13 forks source link

Add destroy-storage command line parameter #133

Closed luissimas closed 1 month ago

luissimas commented 4 months ago

Adds a --destroy-storage CLI argument to enable destroying the storage allocated by Juju on the created models. Without this feature, it is not possible to automatically cleanup storage allocated during the test suite as part of the teardown process.

The behavior is opt-in and can be overridden in a per model basis in a way that resembles the --keep-models argument behavior.

Closes #132

luissimas commented 1 month ago

@addyess any comments on this? If you need any changes please let me know.

We've been using those changes for the past few months in our test environment with machine charms in a 3.5.0 Juju controller over an OpenStack cloud and it's been working flawlessly. With that said it'd be great to get this merged and keep following the upstream repository instead of our fork.

addyess commented 1 month ago

I'll come back and address the failing integration tests. Thanks for the contribution @luissimas