Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataReplacer ¶ added in v0.80.0
DataReplacer takes a generated response and replaces values in it that share a name and type of parameters that were sent in with the request, as determined by the associated OpenAPI schema and the types of incoming values.
This is designed to have the effect of making returned fixtures more realistic while also staying a simple heuristic that doesn't require very much maintenance.
func (*DataReplacer) ReplaceData ¶ added in v0.80.0
func (r *DataReplacer) ReplaceData(requestData map[string]interface{}, responseData map[string]interface{}) map[string]interface{}
ReplaceData projects data from the incoming request into response data as appropriate.
Click to show internal directories.
Click to hide internal directories.