mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Be sure to dup load paths before clearing the array.
This commit is contained in:
parent
c68cc49dcd
commit
b0572ab2b6
2 changed files with 2 additions and 2 deletions
|
@ -9,7 +9,7 @@ class I18nValidationTest < ActiveModel::TestCase
|
|||
Person.reset_callbacks(:validate)
|
||||
@person = Person.new
|
||||
|
||||
@old_load_path, @old_backend = I18n.load_path, I18n.backend
|
||||
@old_load_path, @old_backend = I18n.load_path.dup, I18n.backend
|
||||
I18n.load_path.clear
|
||||
I18n.backend = I18n::Backend::Simple.new
|
||||
I18n.backend.store_translations('en', :errors => {:messages => {:custom => nil}})
|
||||
|
|
|
@ -8,7 +8,7 @@ class I18nValidationTest < ActiveRecord::TestCase
|
|||
def setup
|
||||
Reply.validates_presence_of(:title)
|
||||
@topic = Topic.new
|
||||
@old_load_path, @old_backend = I18n.load_path, I18n.backend
|
||||
@old_load_path, @old_backend = I18n.load_path.dup, I18n.backend
|
||||
I18n.load_path.clear
|
||||
I18n.backend = I18n::Backend::Simple.new
|
||||
I18n.backend.store_translations('en', :errors => {:messages => {:custom => nil}})
|
||||
|
|
Loading…
Reference in a new issue