(t *testing.T, r *http.Request)
| 210 | } |
| 211 | |
| 212 | func checkUpdateAddonVersionRequest(t *testing.T, r *http.Request) { |
| 213 | t.Helper() |
| 214 | |
| 215 | got := map[string]any{} |
| 216 | body, err := io.ReadAll(r.Body) |
| 217 | if err != nil { |
| 218 | t.Fatal(err) |
| 219 | } |
| 220 | err = json.Unmarshal(body, &got) |
| 221 | if err != nil { |
| 222 | t.Fatal(err) |
| 223 | } |
| 224 | if got["draft"].(bool) { |
| 225 | t.Fatalf("expected draft to be false, got %v", got["draft"]) |
| 226 | } |
| 227 | } |
no outgoing calls
no test coverage detected