fix config deprecation warnings in Rails 4

Change-Id: I7f42ef939d2a707c5df657aceef59ee7ace5071b
Reviewed-on: https://gerrit.instructure.com/41576
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
This commit is contained in:
Cody Cutrer 2014-09-22 14:46:46 -06:00
parent ede8bff78a
commit ac3be7b625
3 changed files with 21 additions and 5 deletions

View File

@ -6,8 +6,10 @@ environment_configuration(defined?(config) && config) do |config|
# since you don't have to restart the webserver when you make code changes.
config.cache_classes = false
# Log error messages when you accidentally call methods on nil.
config.whiny_nils = true
if CANVAS_RAILS3
# Log error messages when you accidentally call methods on nil.
config.whiny_nils = true
end
# Show full error reports and disable caching
config.consider_all_requests_local = true
@ -49,4 +51,8 @@ environment_configuration(defined?(config) && config) do |config|
# we use lots of db specific stuff - don't bother trying to dump to ruby
# (it also takes forever)
config.active_record.schema_format = :sql
unless CANVAS_RAILS3
config.eager_load = false
end
end

View File

@ -52,4 +52,8 @@ environment_configuration(defined?(config) && config) do |config|
# we use lots of db specific stuff - don't bother trying to dump to ruby
# (it also takes forever)
config.active_record.schema_format = :sql
unless CANVAS_RAILS3
config.eager_load = true
end
end

View File

@ -39,9 +39,11 @@ environment_configuration(defined?(config) && config) do |config|
# and recreated between test runs. Don't rely on the data there!
config.cache_classes = true
# Log error messages when you accidentally call methods on nil.
# in 1.9, whiny_nils causes a huge performance penalty on tests for some reason
config.whiny_nils = false
if CANVAS_RAILS3
# Log error messages when you accidentally call methods on nil.
# in 1.9, whiny_nils causes a huge performance penalty on tests for some reason
config.whiny_nils = false
end
# Show full error reports and disable caching
config.consider_all_requests_local = true
@ -71,4 +73,8 @@ environment_configuration(defined?(config) && config) do |config|
# Print deprecation notices to the stderr
config.active_support.deprecation = :stderr
unless CANVAS_RAILS3
config.eager_load = false
end
end