This is a good way to delete the regular checks and handlers but with users created in the namespace, the dump doesnot provide with just users of the single namespace. It infact returns all the users across all namespaces. My command
sensuctl --namespace automation dump all -f out.yaml returned all namespaces regardless of the namespace filter while specifically going
sensuctl --namespace automation dump checks,handlers,filters,users -f out.yaml still gave users from other namespaces as well. It would be helpful to know after deleting resources in the namespace, what remains to be deleted.
In my case i did find that the following command almost always cleared all the resources in the namespace
sensuctl --namespace automation dump checks,handlers,filters,assets -f out.yaml
sensuctl delete -f out.yaml
senuctl namespace delete automation