MCPcopy
hub / github.com/valyala/fasthttp / TestUserDataSetAndRemove

Function TestUserDataSetAndRemove

userdata_test.go:109–122  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

107}
108
109func TestUserDataSetAndRemove(t *testing.T) {
110 var (
111 u userData
112 shortKey = "[]"
113 longKey = "[ ]"
114 )
115
116 u.Set(shortKey, "")
117 u.Set(longKey, "")
118 u.Remove(shortKey)
119 u.Set(shortKey, "")
120 testUserDataGet(t, &u, []byte(shortKey), "")
121 testUserDataGet(t, &u, []byte(longKey), "")
122}
123
124func TestUserData_GC(t *testing.T) {
125 t.Parallel()

Callers

nothing calls this directly

Calls 3

testUserDataGetFunction · 0.85
RemoveMethod · 0.80
SetMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…