MCPcopy Create free account
hub / github.com/Mnexa-AI/e2a / TestDeleteDomain

Function TestDeleteDomain

internal/httpapi/domains_test.go:96–108  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

94}
95
96func TestDeleteDomain(t *testing.T) {
97 srv := testServer(t)
98 req, _ := http.NewRequest("DELETE", srv.URL+"/v1/domains/acme.com?confirm=DELETE", nil)
99 req.Header.Set("Authorization", "Bearer good")
100 resp, err := http.DefaultClient.Do(req)
101 if err != nil {
102 t.Fatal(err)
103 }
104 defer resp.Body.Close()
105 if resp.StatusCode != 204 {
106 t.Fatalf("want 204, got %d", resp.StatusCode)
107 }
108}
109
110func TestDeleteDomainRequiresConfirm(t *testing.T) {
111 srv := testServer(t)

Callers

nothing calls this directly

Calls 2

testServerFunction · 0.85
CloseMethod · 0.45

Tested by

no test coverage detected