Damian
06/29/2022, 11:51 PMNo matching interaction found
Any idea why the pact test for the GET request w/ a query param would be failing when it's seemingly identical to the other working pact test?Damian
06/29/2022, 11:58 PMYousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
Damian
06/30/2022, 12:30 AMMatt (pactflow.io / pact-js / pact-go)
query
property? 🤔Timothy Jones
06/30/2022, 1:35 AM?
is not allowed in paths, so it's a trivial checkYousaf Nabi (pactflow.io)
Timothy Jones
06/30/2022, 1:37 AMYousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
Yousaf Nabi (pactflow.io)
Timothy Jones
06/30/2022, 3:39 AMapplication/x-www-form-urlencoded
, but that recommendation is not required by any standard.
An important difference is how spaces work - spaces in application/x-www-form-urlencoded
are encoded as +
, but in general URLs, they're URL encoded to %20
.
Also, there's no standard at all for repeat parameters - some implementations will do key=val1&key=val2
, some will do key[]=val1&key[]=val2
, and some will do key[1]=val1&key[2]=val2
. I think key[]
is what pact does (and the most common interpretation), but I don't actually know. The W3C recommendation is just to treat it as a list of pairs, and doesn't say that the keys need to be unique.Yousaf Nabi (pactflow.io)