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

Function TestAppendTopLevelArray

append_test.go:11–19  ·  view source on GitHub ↗

Verifies: SYS-REQ-110 (Set/array append) reqproof:proptest:skip

(t *testing.T)

Source from the content-addressed store, hash-verified

9// Verifies: SYS-REQ-110 (Set/array append)
10// reqproof:proptest:skip
11func TestAppendTopLevelArray(t *testing.T) {
12 got, err := Append([]byte(`[1,2,3]`), []byte(`4`))
13 if err != nil {
14 t.Fatalf("Append returned error: %v", err)
15 }
16 if want := `[1,2,3,4]`; string(got) != want {
17 t.Fatalf("Append result = %s, want %s", got, want)
18 }
19}
20
21// Verifies: SYS-REQ-110 (Set/array append)
22// reqproof:proptest:skip

Callers

nothing calls this directly

Calls 1

AppendFunction · 0.85

Tested by

no test coverage detected