You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I test the above routes with a browser, it works as expected, and I can see that cookie-session sets two cookies, one for the session object, and one for the signature (session.sig), as the log shows:
I have the followin test routes, the first sets a cookie, the second retrieves it.
I am using cookie-session: https://github.com/expressjs/cookie-session
to handle sessions
When I test the above routes with a browser, it works as expected, and I can see that cookie-session sets two cookies, one for the session object, and one for the signature (session.sig), as the log shows:
cookie header: _ga=GA1.1.984665860.1553382018; session=eyJ2IjoicXEifQ==; session.sig=kJH4iEj4NkYR4HwYyo0QI42fF9A
When I use supertest-session, only one cookie gets set, as show by the log :
cookie header: session=eyJ2IjoicXdlcnR5In0=
Which causes cookie-session to not recognize the session, since it has no signature cookie.
The jest / supertest-session code is below.
Is there a way to tell supertest-session to persist all cookies set during a request ?
The text was updated successfully, but these errors were encountered: