Merge pull request #887 from joaomdmoura/fixing-jruby-tests

Fixing tests on JRuby
This commit is contained in:
João Moura 2015-04-27 16:16:42 -03:00
commit 40d95c2d8a
2 changed files with 5 additions and 4 deletions

View File

@ -319,13 +319,13 @@ module ActionController
response = JSON.parse(@response.body)
expected_return = {
"id"=>1,
"time"=>DateTime.now.to_s,
"post" => {
"id"=>1,
"title"=>"New Post",
"body"=>"Body"
},
"id"=>1,
"time"=>DateTime.now.to_s
}
}
assert_equal 'application/json', @response.content_type

View File

@ -12,7 +12,8 @@ Minitest::Test = MiniTest::Unit::TestCase unless defined?(Minitest::Test)
class Foo < Rails::Application
if Rails.version.to_s.start_with? '4'
config.action_controller.perform_caching = true
ActionController::Base.cache_store = :memory_store
config.active_support.test_order = :random
ActionController::Base.cache_store = :memory_store
end
end