Verifies: SYS-REQ-082 [malformed] GetUnsafeString on truncated-at-value-boundary input shall return error.
(t *testing.T)
| 805 | // Verifies: SYS-REQ-082 [malformed] |
| 806 | // GetUnsafeString on truncated-at-value-boundary input shall return error. |
| 807 | func TestGetUnsafeStringTruncatedValue(t *testing.T) { |
| 808 | func() { |
| 809 | defer func() { |
| 810 | if r := recover(); r != nil { |
| 811 | t.Fatalf("GetUnsafeString on truncated input panicked: %v", r) |
| 812 | } |
| 813 | }() |
| 814 | _, err := GetUnsafeString([]byte(`{"a":1`), "a") |
| 815 | // Accept error or best-effort result, as long as no panic |
| 816 | _ = err |
| 817 | }() |
| 818 | } |
| 819 | |
| 820 | // ============================================================================= |
| 821 | // ArrayEach truncated at value boundary (SYS-REQ-083) |
nothing calls this directly
no test coverage detected
searching dependent graphs…