Documentation ¶
Index ¶
- Constants
- Variables
- func ArrayMatch(match interface{}, toMatch string, config map[string]interface{}) bool
- func ArrayMatchWithoutConfig(match interface{}, toMatch string) bool
- func ExactMatch(match interface{}, toMatch string) bool
- func GetDecodedJsonData(str string) (interface{}, error)
- func GlobMatch(match interface{}, toMatch string) bool
- func IdentityValueGenerator(match interface{}, toMatch string) string
- func JsonMatch(match interface{}, toMatch string) bool
- func JsonPartialMatch(match interface{}, toMatch string) bool
- func JsonPathMatch(match interface{}, toMatch string) bool
- func JsonPathMatcherValueGenerator(match interface{}, toMatch string) string
- func JwtMatchValueGenerator(match interface{}, toMatch string) string
- func JwtMatcher(data interface{}, toMatch string) bool
- func NegationMatch(match interface{}, toMatch string) bool
- func ParseJWT(str string) (string, error)
- func RegexMatch(match interface{}, toMatch string) bool
- func XPathMatchValueGenerator(match interface{}, toMatch string) string
- func XmlMatch(match interface{}, toMatch string) bool
- func XmlTemplatedMatch(match interface{}, toMatch string) bool
- func XpathMatch(match interface{}, toMatch string) bool
- type MatcherDetails
- type MatcherFunc
- type MatcherFuncWithConfig
- type MatcherValueGenerator
Constants ¶
View Source
const ( IgnoreUnknown = "ignoreUnknown" IgnoreOrder = "ignoreOrder" IgnoreOccurrences = "ignoreOccurrences" )
Variables ¶
View Source
var Array = "array"
View Source
var Exact = "exact"
View Source
var Glob = "glob"
View Source
var JWT = "jwt"
View Source
var Json = "json"
View Source
var JsonPartial = "jsonpartial"
View Source
var JsonPath = "jsonpath"
View Source
var Matchers = map[string]MatcherDetails{ "": { MatcherFunction: ExactMatch, MatchValueGenerator: IdentityValueGenerator, }, Exact: { MatcherFunction: ExactMatch, MatchValueGenerator: IdentityValueGenerator, }, Glob: { MatcherFunction: GlobMatch, MatchValueGenerator: IdentityValueGenerator, }, Json: { MatcherFunction: JsonMatch, MatchValueGenerator: IdentityValueGenerator, }, JsonPath: { MatcherFunction: JsonPathMatch, MatchValueGenerator: JsonPathMatcherValueGenerator, }, JsonPartial: { MatcherFunction: JsonPartialMatch, MatchValueGenerator: IdentityValueGenerator, }, Regex: { MatcherFunction: RegexMatch, MatchValueGenerator: IdentityValueGenerator, }, Xml: { MatcherFunction: XmlMatch, MatchValueGenerator: IdentityValueGenerator, }, Xpath: { MatcherFunction: XpathMatch, MatchValueGenerator: XPathMatchValueGenerator, }, XmlTemplated: { MatcherFunction: XmlTemplatedMatch, MatchValueGenerator: IdentityValueGenerator, }, Array: { MatcherFunction: ArrayMatchWithoutConfig, MatchValueGenerator: IdentityValueGenerator, }, JWT: { MatcherFunction: JwtMatcher, MatchValueGenerator: JwtMatchValueGenerator, }, Negation: { MatcherFunction: NegationMatch, MatchValueGenerator: IdentityValueGenerator, }, }
View Source
var MatchersWithConfig = map[string]MatcherDetails{ Array: { MatcherFunction: ArrayMatch, MatchValueGenerator: IdentityValueGenerator, }, }
View Source
var Negation = "negate"
View Source
var Regex = "regex"
View Source
var Xml = "xml"
View Source
var XmlTemplated = "xmltemplated"
View Source
var Xpath = "xpath"
Functions ¶
func ArrayMatch ¶ added in v1.5.0
func ArrayMatchWithoutConfig ¶ added in v1.5.0
func ExactMatch ¶
func GetDecodedJsonData ¶ added in v1.5.0
func IdentityValueGenerator ¶ added in v1.5.0
func JsonPartialMatch ¶ added in v1.0.0
func JsonPathMatch ¶
func JsonPathMatcherValueGenerator ¶ added in v1.5.0
func JwtMatchValueGenerator ¶ added in v1.5.0
func JwtMatcher ¶ added in v1.5.0
func NegationMatch ¶ added in v1.9.0
func RegexMatch ¶
func XPathMatchValueGenerator ¶ added in v1.5.0
func XmlTemplatedMatch ¶ added in v1.2.0
func XpathMatch ¶
Types ¶
type MatcherDetails ¶ added in v1.5.0
type MatcherDetails struct { MatcherFunction interface{} MatchValueGenerator MatcherValueGenerator }
type MatcherFunc ¶
type MatcherFuncWithConfig ¶ added in v1.5.0
type MatcherValueGenerator ¶ added in v1.5.0
this is called only if matcher returns true and there is chaining to feed value this is set as nil for matchers where we are doing complete details match and there is no need of chaining
Click to show internal directories.
Click to hide internal directories.