If you’re recieving HTTP 500 errors during your integration tests on Rails, here’s a gotcha. If you’re running version 2.x, dig into your test.log. If you find
Status: 500 Internal Server Error
You’ve come across [this lovely bug](https://rails.lighthouseapp.com/projects/8994/tickets/1453-gets-in-integration-test-unless-you-are-using-cookie-sessions). The fix is pretty simple luckily enough; add the following to your `/config/environments/test.rb`:
ActionController::RackRequest::DEFAULT_SESSION_OPTIONS[:database_manager] = CGI::Session::ActiveRecordStore
You should now be able to integration test to your heart’s content.