MCPcopy Create free account
hub / github.com/allegro/bigcache / TestGetWithMissingKey

Function TestGetWithMissingKey

server/server_test.go:50–61  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

48}
49
50func TestGetWithMissingKey(t *testing.T) {
51 t.Parallel()
52 req := httptest.NewRequest("GET", testBaseString+"/api/v1/cache/doesNotExist", nil)
53 rr := httptest.NewRecorder()
54
55 getCacheHandler(rr, req)
56 resp := rr.Result()
57
58 if resp.StatusCode != 404 {
59 t.Errorf("want: 404; got: %d", resp.StatusCode)
60 }
61}
62
63func TestGetKey(t *testing.T) {
64 t.Parallel()

Callers

nothing calls this directly

Calls 1

getCacheHandlerFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…