DeleteBuildpackIfOnOldCCAPI deletes the buildpack if the CC API targeted by the current test run is <= 2.80.0. Before this version, some entities would receive and invalid next_url in paginated requests. Since our test run now generally creates more than 50 buildpacks, we need to delete test buildpa
(buildpackName string)
| 138 | // after use if we are targeting an older CC API. |
| 139 | // see https://github.com/cloudfoundry/capi-release/releases/tag/1.45.0 |
| 140 | func DeleteBuildpackIfOnOldCCAPI(buildpackName string) { |
| 141 | minVersion := "2.99.0" |
| 142 | if !IsVersionMet(minVersion) { |
| 143 | deleteSessions := CF("delete-buildpack", buildpackName, "-f") |
| 144 | Eventually(deleteSessions).Should(Exit()) |
| 145 | } |
| 146 | } |
| 147 | |
| 148 | type Buildpack struct { |
| 149 | GUID string `json:"guid"` |
no test coverage detected