bug(overrider): unmocked HTTPS request with partial interceptor match#1664
Merged
mastermatt merged 1 commit intonock:nextfrom Aug 14, 2019
Merged
bug(overrider): unmocked HTTPS request with partial interceptor match#1664mastermatt merged 1 commit intonock:nextfrom
mastermatt merged 1 commit intonock:nextfrom
Conversation
Fixes: nock#1422 The `allowUnmocked` option is processed in two places. Once in the intercept when there are no interceptors that come close to matching the request. And again in the overrider when there are interceptors that partially match, eg just path, but don't completely match. This fixes and explicitly tests the later case in the overrider by making an HTTPS request for a path that has an interceptor but fails to match the query constraint.
Member
Author
|
fyi @NatalieWolfe |
Member
Author
|
@paulmelnikow @gr2m can this get in before 11 publishes |
Member
paulmelnikow
left a comment
There was a problem hiding this comment.
Sorry, had a review started on this but looks like I didn't click the button.
Thanks for fixing this!
| }) | ||
| }) | ||
|
|
||
| test('allow unmocked option works with https for a partial match', t => { |
Member
There was a problem hiding this comment.
Could you add a link here to the issue?
Collaborator
|
🎉 This PR is included in version 11.1.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
gr2m
pushed a commit
that referenced
this pull request
Sep 4, 2019
…#1664) Fixes: #1422 The `allowUnmocked` option is processed in two places. Once in the intercept when there are no interceptors that come close to matching the request. And again in the overrider when there are interceptors that partially match, eg just path, but don't completely match. This fixes and explicitly tests the later case in the overrider by making an HTTPS request for a path that has an interceptor but fails to match the query constraint.
gr2m
pushed a commit
that referenced
this pull request
Sep 4, 2019
…#1664) Fixes: #1422 The `allowUnmocked` option is processed in two places. Once in the intercept when there are no interceptors that come close to matching the request. And again in the overrider when there are interceptors that partially match, eg just path, but don't completely match. This fixes and explicitly tests the later case in the overrider by making an HTTPS request for a path that has an interceptor but fails to match the query constraint.
gr2m
pushed a commit
that referenced
this pull request
Sep 5, 2019
…#1664) Fixes: #1422 The `allowUnmocked` option is processed in two places. Once in the intercept when there are no interceptors that come close to matching the request. And again in the overrider when there are interceptors that partially match, eg just path, but don't completely match. This fixes and explicitly tests the later case in the overrider by making an HTTPS request for a path that has an interceptor but fails to match the query constraint.
juninmd
pushed a commit
to juninmd/nock
that referenced
this pull request
Mar 21, 2026
…nock#1664) Fixes: nock#1422 The `allowUnmocked` option is processed in two places. Once in the intercept when there are no interceptors that come close to matching the request. And again in the overrider when there are interceptors that partially match, eg just path, but don't completely match. This fixes and explicitly tests the later case in the overrider by making an HTTPS request for a path that has an interceptor but fails to match the query constraint.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes: #1422
The
allowUnmockedoption is processed in two places. Once in theintercept when there are no interceptors that come close to matching
the request. And again in the overrider when there are interceptors
that partially match, eg just path, but don't completely match.
This fixes and explicitly tests the later case in the overrider by
making an HTTPS request for a path that has an interceptor but fails to
match the query constraint.