Reset the locale after tests that may change it
This commit is contained in:
parent
cd973c241f
commit
9f263dd9c3
2 changed files with 12 additions and 0 deletions
|
@ -3,6 +3,14 @@ require "test_helper"
|
|||
class LocaleTest < ActionDispatch::IntegrationTest
|
||||
fixtures :users
|
||||
|
||||
def setup
|
||||
I18n.locale = "en"
|
||||
end
|
||||
|
||||
def teardown
|
||||
I18n.locale = "en"
|
||||
end
|
||||
|
||||
def test_defaulting
|
||||
user = users(:second_public_user)
|
||||
|
||||
|
|
|
@ -4,10 +4,14 @@ class UserCreationTest < ActionDispatch::IntegrationTest
|
|||
fixtures :users
|
||||
|
||||
def setup
|
||||
I18n.locale = "en"
|
||||
|
||||
OmniAuth.config.test_mode = true
|
||||
end
|
||||
|
||||
def teardown
|
||||
I18n.locale = "en"
|
||||
|
||||
OmniAuth.config.mock_auth[:openid] = nil
|
||||
OmniAuth.config.test_mode = false
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue