MCPcopy Create free account
hub / github.com/aws/aws-lambda-go / TestSafeMarshal_SerializationError

Function TestSafeMarshal_SerializationError

lambda/invoke_loop_test.go:438–442  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

436}
437
438func TestSafeMarshal_SerializationError(t *testing.T) {
439 payload := safeMarshal(invalidPayload{})
440 want := `{"errorMessage":"json: error calling MarshalJSON for type lambda.invalidPayload: some error that contains '\"'","errorType":"Runtime.SerializationError"}`
441 assert.Equal(t, want, string(payload))
442}
443
444type requestRecord struct {
445 lock sync.Mutex

Callers

nothing calls this directly

Calls 1

safeMarshalFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…