You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And then enable a "startsWith" checkbox. Mocking would then only match on the beginning of the url. So any api staring with the string would match.
Another idea would be to define the url with a regular expression (as an option).
Would this feature be interesting/useful to anyone?
The text was updated successfully, but these errors were encountered:
bizzguy
changed the title
Discussion: Network Plugin - Add checkbox for enable a "starts with" match on mocks
Discussion: Network Plugin - Add checkbox for enabling a "starts with" match on mocks
Apr 2, 2021
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.
Any news on this issue? Some wildcard character or similar? Regex? Other workarounds around the issue? At the moment I have to mock an API with current timestamp in query parameter so I can't mock the call at all unless I can ignore the value of the timestamp
Currently a mock route is identified with a key of "http method" and "url".
I'm suggesting that an additional matching method be added.
The API I'm currently using as some extraneous qualifiers at the end that I would like to ignore.
For example. The API might look like this:
https://www.example.com/query/product?id=123&page=2&other=7
https://www.example.com/query/product?id=123&page=3&other=9
I would really like the mocks to ignore the parameters at the end so that I would define the mock as
https://www.example.com/query/product?id=123
And then enable a "startsWith" checkbox. Mocking would then only match on the beginning of the url. So any api staring with the string would match.
Another idea would be to define the url with a regular expression (as an option).
Would this feature be interesting/useful to anyone?
The text was updated successfully, but these errors were encountered: