We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi, There is a issue with mocking header set-cookie and when i try mocking multiple set-cookie
Example: When i mock request
mockAgent.get(accountFrontHost).intercept({ path: '/user/login', method: 'POST', body: JSON.stringify(expectedPostUserLoginBody), query: expectedPostUserLoginParams, headers: {'Accept-Version': '1.0.0', 'Content-Type': 'application/json'} }).reply(204, {},{ headers: { 'set-cookie': [ 'aaaaaaaa=bbbbbbbbbbbbbbbbbb; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure; SameSite=None', 'cccccccc=dddddddddddddddddd; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure', 'eeeeeeeeeee=ffffffffffffffff; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure; SameSite=None' ] }});
Mock "flattens" the set-cookie and reply as string not as array of strings
statusCode: 204, headers: { 'set-cookie': 'aaaaaaaa=bbbbbbbbbbbbbbbbbb; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure; SameSite=None,cccccccc=dddddddddddddddddd; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure,eeeeeeeeeee=ffffffffffffffff; Domain=.example.pl; Path=/; Expires=Fri, 07 Jul 2023 10:04:22 GMT; HttpOnly; Secure; SameSite=None' },
The text was updated successfully, but these errors were encountered:
Thanks for reporting! Would you like to send a Pull Request to address this issue? Remember to add unit tests.
Sorry, something went wrong.
Hi, i would like to work on this if @marekjaskot isn't interested
go for it!
Successfully merging a pull request may close this issue.
Hi,
There is a issue with mocking header set-cookie and when i try mocking multiple set-cookie
Example: When i mock request
Mock "flattens" the set-cookie and reply as string not as array of strings
The text was updated successfully, but these errors were encountered: