MCPcopy Create free account
hub / github.com/0xUnixIO/pulse / TestNodeEnrollToken_NotFound

Function TestNodeEnrollToken_NotFound

internal/serverapi/node_enroll_token_test.go:120–128  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

118}
119
120func TestNodeEnrollToken_NotFound(t *testing.T) {
121 store := enrolltokens.NewMemoryStore()
122 mux := newEnrollTokenTestMux(t, store) // no nodes seeded
123
124 w := doEnrollToken(t, mux, "ghost", nil)
125 if w.Code != http.StatusNotFound {
126 t.Fatalf("status=%d body=%s", w.Code, w.Body.String())
127 }
128}
129
130func TestNodeEnrollToken_InvalidJSON(t *testing.T) {
131 store := enrolltokens.NewMemoryStore()

Callers

nothing calls this directly

Calls 4

NewMemoryStoreFunction · 0.92
newEnrollTokenTestMuxFunction · 0.85
doEnrollTokenFunction · 0.85
StringMethod · 0.45

Tested by

no test coverage detected