MCPcopy Create free account
hub / github.com/buger/jsonparser / TestGetUnsafeStringEmptyInput

Function TestGetUnsafeStringEmptyInput

deep_spec_test.go:812–817  ·  view source on GitHub ↗

Verifies: SYS-REQ-081 [boundary] GetUnsafeString on empty input shall return error.

(t *testing.T)

Source from the content-addressed store, hash-verified

810// Verifies: SYS-REQ-081 [boundary]
811// GetUnsafeString on empty input shall return error.
812func TestGetUnsafeStringEmptyInput(t *testing.T) {
813 _, err := GetUnsafeString([]byte(``), "a")
814 if err == nil {
815 t.Fatal("GetUnsafeString on empty input should return error")
816 }
817}
818
819// Verifies: SYS-REQ-082 [malformed]
820// GetUnsafeString on truncated-at-value-boundary input shall return error.

Callers

nothing calls this directly

Calls 1

GetUnsafeStringFunction · 0.85

Tested by

no test coverage detected