Created
May 14, 2012 16:30
-
-
Save kennethkalmer/2694930 to your computer and use it in GitHub Desktop.
Rspec controller specs & signed cookies (http://stackoverflow.com/a/9094206/284612)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Requires supporting ruby files with custom matchers and macros, etc, | |
# in spec/support/ and its subdirectories. | |
Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f} | |
RSpec.configure do |config| | |
# omitted... | |
# Include our #signed_cookie helper method in our controller specs | |
config.include SignedCookies, :type => :controller | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
getting
Also, this code seems to allow to set and look into cookies, but will it work to verify cookies were set the normal way in controller code?
thanks