I have a general application behavior that changes based on cookie content and you need to test it. As an example, if a user does not have a set of cookies indicating that they have accepted the terms of the site, they need to be redirected to the T & C.
I can set a cookie in a functional test using
request.cookies["legal_accepted"] = "yes"
However, this will not work in the integration test - there is no request object there. I could not find the documentation on why this is so, what is not yet, and best practices for dealing with the difference. How to set a cookie for this request? Why and where is it documented?
source share