If you want to validate your transform functions:
- create a sub-directory
- create a file named cleaner.yaml containing your Cleaner instance
- create a file named matching.yaml containing a resource that matches your Cleaner.ResourcePolicySet.ResourceSelector
- create a file named updated.yaml containing the expected resource after Cleaner.ResourcePolicySet.Tranform is executed
- run
make test
That will run the exact code Cleaner will run in your cluster. If you see no error, your Cleaner instance is correct
This validates both Cleaner.ResourcePolicySet.ResourceSelector and Cleaner.ResourcePolicySet.Transform
If you need to validate your aggregatedSelection function follow instruction in validate_aggregatedselection directory