I am trying to define a stub:
{
"predicates":[
{
"equals":{
"method":"GET",
"path":"/sword/eBISXMLInvoice2.do",
"query": {
"action": "index",
"page": 3 <-- this one!
}
}
}
],
"responses":[
{
"is":{
"statusCode":200,
"headers":{
"Content-Type":"application/xml"
},
"body":"<doclist><document uuid='101654' type='invoice' date='2018-11-14 13:49:43' /></doclist>"
}
}
]
}
One of the expected query string parameters (called "page") can have multiple values. How can I define the predicate to handle this?
My question is actually very easy to answer. According to the docs, the "equals" predicate, will match if any value matches.
Full text:
So I can just remove the changeable query string value from the predicate, or I can keep it in there, it doesn't matter.