Add a site setting to allow users to toggle I18n.locale

It is false by default.
This commit is contained in:
Jonathan Allard
2014-02-08 20:35:46 -05:00
parent c513725f26
commit 0592420e52
7 changed files with 29 additions and 9 deletions

View File

@ -55,6 +55,15 @@ describe TopicsController do
I18n.locale.should == :fr
end
it 'is sets the default locale when the setting not enabled' do
user = Fabricate(:user, locale: :fr)
log_in_user(user)
get :show, {topic_id: topic.id}
I18n.locale.should == :en
end
end
end