-
Notifications
You must be signed in to change notification settings - Fork 24.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(common): http/testing expectOne lists the received requests #27005
Conversation
3571fe7
to
9d8d0b7
Compare
9d8d0b7
to
347c333
Compare
f87c9f4
to
0996ee3
Compare
0996ee3
to
6a992b8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One NIT but otherwise LGTM.
Caretaker: the presubmit errors are legit. 290817196 contains the necessary g3 patches. |
e98044a
to
b99ca9e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
… matches Fixes angular#18013 Previously it was hard to debug an `expectOne` if the request had no match, as the error message was: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. This commit adds a bit more info to the error, by listing the actual requests received: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. Requests received are: POST /some-url?query=world.
b99ca9e
to
3c1840a
Compare
FYI, I submitted a change in g3 to adapt some code to upcoming changes from this PR. Once it's merged, I will run another presubmit and remove the "blocked" label if everything goes well. Thank you. |
FYI, g3 presubmit is now passing (after respective changes in g3), this PR is ready to be merged. |
… matches (#27005) Fixes #18013 Previously it was hard to debug an `expectOne` if the request had no match, as the error message was: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. This commit adds a bit more info to the error, by listing the actual requests received: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. Requests received are: POST /some-url?query=world. PR Close #27005
… matches (#27005) Fixes #18013 Previously it was hard to debug an `expectOne` if the request had no match, as the error message was: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. This commit adds a bit more info to the error, by listing the actual requests received: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. Requests received are: POST /some-url?query=world. PR Close #27005
… matches (angular#27005) Fixes angular#18013 Previously it was hard to debug an `expectOne` if the request had no match, as the error message was: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. This commit adds a bit more info to the error, by listing the actual requests received: Expected one matching request for criteria "Match URL: /some-url?query=hello", found none. Requests received are: POST /some-url?query=world. PR Close angular#27005
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
Previously it was hard to debug an
expectOne
if the request had no match, as the error message was:Issue Number: #18013
What is the new behavior?
This commit adds a bit more info to the error, by listing the actual requests received, if there are some (doesn't change the message if no requests were received):
Does this PR introduce a breaking change?