MCPcopy Create free account
hub / github.com/buggregator/server / TestIsAllDigits

Function TestIsAllDigits

modules/sentry/handler_test.go:207–228  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

205}
206
207func TestIsAllDigits(t *testing.T) {
208 tests := []struct {
209 s string
210 want bool
211 }{
212 {"007", true},
213 {"0", true},
214 {"", false},
215 {"+1", false},
216 {" 1", false},
217 {"1.0", false},
218 {"abc", false},
219 }
220
221 for _, tt := range tests {
222 t.Run(tt.s, func(t *testing.T) {
223 if got := isAllDigits(tt.s); got != tt.want {
224 t.Errorf("isAllDigits(%q) = %v, want %v", tt.s, got, tt.want)
225 }
226 })
227 }
228}
229
230func TestHandleEnvelope(t *testing.T) {
231 h := &handler{} // no db — structured storage silently skipped

Callers

nothing calls this directly

Calls 2

isAllDigitsFunction · 0.85
RunMethod · 0.45

Tested by

no test coverage detected