Alright! I'm currently in the process of refactoring some tests using minitest (with Rails), will let you know what would potentially work for me (hopefully).
I've spelunked the rails code source, #cookies in minitest always refers to the request's cookies ( even after the HTTP call), and is a Rack::Test::CookieJar instance, whereas response.cookies is a plain ruby hash containing the responses's cookies. I'm going to instantiate a rails Cookie Jar as suggested in your article, but using response.cookies as the second argument.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Alright! I'm currently in the process of refactoring some tests using minitest (with Rails), will let you know what would potentially work for me (hopefully).
I've spelunked the rails code source,
#cookies
in minitest always refers to the request's cookies ( even after the HTTP call), and is aRack::Test::CookieJar
instance, whereasresponse.cookies
is a plain ruby hash containing the responses's cookies. I'm going to instantiate a rails Cookie Jar as suggested in your article, but usingresponse.cookies
as the second argument.