MCPcopy
hub / github.com/gin-gonic/gin / TestMappingSkipField

Function TestMappingSkipField

binding/form_mapping_test.go:87–95  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

85}
86
87func TestMappingSkipField(t *testing.T) {
88 var s struct {
89 A int
90 }
91 err := mappingByPtr(&s, formSource{}, "form")
92 require.NoError(t, err)
93
94 assert.Equal(t, 0, s.A)
95}
96
97func TestMappingIgnoreField(t *testing.T) {
98 var s struct {

Callers

nothing calls this directly

Calls 1

mappingByPtrFunction · 0.85

Tested by

no test coverage detected