MCPcopy Create free account
hub / github.com/google/go-github / TestOrganizationsService_Delete

Function TestOrganizationsService_Delete

github/orgs_test.go:317–340  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

315}
316
317func TestOrganizationsService_Delete(t *testing.T) {
318 t.Parallel()
319 client, mux, _ := setup(t)
320
321 mux.HandleFunc("/orgs/o", func(_ http.ResponseWriter, r *http.Request) {
322 testMethod(t, r, "DELETE")
323 })
324
325 ctx := t.Context()
326 _, err := client.Organizations.Delete(ctx, "o")
327 if err != nil {
328 t.Errorf("Organizations.Delete returned error: %v", err)
329 }
330
331 const methodName = "Delete"
332 testBadOptions(t, methodName, func() (err error) {
333 _, err = client.Organizations.Delete(ctx, "\n")
334 return err
335 })
336
337 testNewRequestAndDoFailure(t, methodName, client, func() (*Response, error) {
338 return client.Organizations.Delete(ctx, "o")
339 })
340}
341
342func TestOrganizationsService_ListInstallations(t *testing.T) {
343 t.Parallel()

Callers

nothing calls this directly

Calls 5

testMethodFunction · 0.85
testBadOptionsFunction · 0.85
setupFunction · 0.70
DeleteMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…