mirror of
https://github.com/TracksApp/tracks.git
synced 2025-09-22 05:50:47 +02:00
Fixed failing integration tests by using MemoryStore instead of CookieStore for tests. See http://groups.google.com/group/rubyonrails-talk/browse_thread/thread/5519ca7fd4dde3c1. Wohooo passing tests!
This commit is contained in:
parent
07426ebe54
commit
b97fc2d958
1 changed files with 14 additions and 0 deletions
|
@ -19,6 +19,20 @@ config.action_mailer.delivery_method = :test
|
|||
# Disable request forgery protection in test environment
|
||||
config.action_controller.allow_forgery_protection = false
|
||||
|
||||
# We store more than 4K of data in the session during some tests.
|
||||
# Override the hard-coded cookie session store to use a memory store for tests.
|
||||
# See http://groups.google.com/group/rubyonrails-talk/browse_thread/thread/5519ca7fd4dde3c1
|
||||
class ActionController::RackRequest
|
||||
DEFAULT_SESSION_OPTIONS = {
|
||||
:database_manager => CGI::Session::MemoryStore, # store data in memory
|
||||
:prefix => "ruby_sess.", # prefix session file names
|
||||
:session_path => "/", # available to all paths in app
|
||||
:session_key => "_session_id",
|
||||
:cookie_only => false,
|
||||
:session_http_only=> true
|
||||
}
|
||||
end
|
||||
|
||||
# Overwrite the default settings for fixtures in tests. See Fixtures
|
||||
# for more details about these settings.
|
||||
# config.transactional_fixtures = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue