i18n 0.6.8 → 0.6.9
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of i18n might be problematic. Click here for more details.
- data/lib/i18n/config.rb +1 -1
- data/lib/i18n/version.rb +1 -1
- data/test/i18n_test.rb +9 -0
- metadata +3 -3
data/lib/i18n/config.rb
CHANGED
@@ -111,7 +111,7 @@ module I18n
|
|
111
111
|
# [Deprecated] this will default to true in the future
|
112
112
|
# Defaults to nil so that it triggers the deprecation warning
|
113
113
|
def enforce_available_locales
|
114
|
-
@@enforce_available_locales
|
114
|
+
defined?(@@enforce_available_locales) ? @@enforce_available_locales : nil
|
115
115
|
end
|
116
116
|
|
117
117
|
def enforce_available_locales=(enforce_available_locales)
|
data/lib/i18n/version.rb
CHANGED
data/test/i18n_test.rb
CHANGED
@@ -353,4 +353,13 @@ class I18nTest < Test::Unit::TestCase
|
|
353
353
|
I18n.config.enforce_available_locales = false
|
354
354
|
end
|
355
355
|
end
|
356
|
+
|
357
|
+
test "I18n.enforce_available_locales config can be set to false" do
|
358
|
+
begin
|
359
|
+
I18n.config.enforce_available_locales = false
|
360
|
+
assert_equal false, I18n.config.enforce_available_locales
|
361
|
+
ensure
|
362
|
+
I18n.config.enforce_available_locales = false
|
363
|
+
end
|
364
|
+
end
|
356
365
|
end
|
metadata
CHANGED