This repository has been archived by the owner on Aug 24, 2023. It is now read-only.
Feature request: expect how many times a request has been made #21
Labels
enhancement
New feature or request
Currently, we can only check IF a request has been made using
expectRequestToHaveBeenMade
andexpectRequestNotToHaveBeenMade
. From internal statistics at trayio, these two methods are by far the most popular ones in the library.Extending on this I think it would be nice to be able to expect how often a request was made. I suggest the following API:
The particularity of this is that this would currently only work if
persistent: true
is used. Otherwise, the mock response will only take effect one single time when the request is made.The text was updated successfully, but these errors were encountered: