httmock icon indicating copy to clipboard operation
httmock copied to clipboard

poor documentation

Open juliabiro opened this issue 10 years ago • 6 comments

please elaborate on how to capture complex urls with urlmatch. the query, scheme etc parameters are not mentioned anywhere in the documentation, neither is the fact that you cannot match for exacts complex urls with the url parameter. Otherwise great tool, but it took several hours to figure out how to use it.

juliabiro avatar May 18 '15 14:05 juliabiro

+1 also some trace logging about what is being mocked would be great

dylanwilder avatar Nov 12 '15 21:11 dylanwilder

:+1: i can't find any docs at all besides the short README

oryband avatar Feb 03 '16 13:02 oryband

Good example is here https://www.appneta.com/blog/python-unit-test-mock/ and the source files to go with it showing a nice way of doing domain / url based matching https://github.com/danriti/python-mocked-service

iwasrobbed avatar Feb 24 '16 00:02 iwasrobbed

+1 for some more documentation. I have just gotcha'd by the having to match the remote address and path separately.

It would also be great if there was a way of implementing a 'catchall' to catch all requests that do not match the given paths, so that you can use the mock to trap bugs due to incorrect paths & spellings. Let me know if this should be logged as a separate issue.

RichardForshaw avatar Jun 29 '16 01:06 RichardForshaw

While the documentation would be great to have, you can have multiple handlers active at the same time, each with its own matching rules. If you make the outer-most match all requests, it should give you the catch-all you described.

patrys avatar Jun 29 '16 07:06 patrys

yes, more documentation would be great!

pmg007 avatar Nov 27 '19 19:11 pmg007