vatesfr / terraform-provider-xenorchestra

Xen Orchestra provider for Terraform
MIT License
150 stars 33 forks source link

Add test sweepers for the existing resources #187

Closed ddelnano closed 2 years ago

ddelnano commented 2 years ago

This addresses #84 and will aid in merging #179

Testing

$ TEST=TestAccXenorchestraVm_createWithShorterResourceTimeout make testacc === RUN TestAccXenorchestraVm_createWithShorterResourceTimeout === PAUSE TestAccXenorchestraVm_createWithShorterResourceTimeout === CONT TestAccXenorchestraVm_createWithShorterResourceTimeout --- PASS: TestAccXenorchestraVm_createWithShorterResourceTimeout (22.65s) PASS [DEBUG] Running sweeper ok github.com/ddelnano/terraform-provider-xenorchestra/xoa 40.988s testing: warning: no tests to run PASS ok github.com/ddelnano/terraform-provider-xenorchestra/xoa/internal 0.040s [no tests to run]

Test passes the second time and Vm is deleted before the second test runs

$ TEST=TestAccXenorchestraVm_createWithShorterResourceTimeout make testacc

[ ... ]

[DEBUG] Deleting vm terraform-acc - TestAccXenorchestraVm_createWithShorterResourceTimeout