QuickDeleteOrg deletes the org with the given name, if provided, using 'cf curl /v3/organizations... -X DELETE'.
(orgName string)
| 114 | // QuickDeleteOrg deletes the org with the given name, if provided, using |
| 115 | // 'cf curl /v3/organizations... -X DELETE'. |
| 116 | func QuickDeleteOrg(orgName string) { |
| 117 | // If orgName is empty, the BeforeSuite has failed and attempting to delete |
| 118 | // will produce a meaningless error. |
| 119 | if orgName == "" { |
| 120 | fmt.Println("Empty org name. Skipping deletion.") |
| 121 | return |
| 122 | } |
| 123 | |
| 124 | guid := GetOrgGUID(orgName) |
| 125 | url := fmt.Sprintf("/v3/organizations/%s", guid) |
| 126 | session := CF("curl", "-X", "DELETE", url) |
| 127 | Eventually(session).Should(Exit(0)) |
| 128 | } |
| 129 | |
| 130 | // QuickDeleteOrgIfExists deletes the org with the given name, if it exists, using |
| 131 | // 'cf curl /v3/organizations... -X DELETE'. |
no test coverage detected