Class: I18nSimpleBackendLookupTest
- Inherits:
-
Test::Unit::TestCase
- Object
- Test::Unit::TestCase
- I18nSimpleBackendLookupTest
- Includes:
- I18nSimpleBackendTestSetup
- Defined in:
- lib/vendor/i18n/test/simple_backend_test.rb
Instance Method Summary collapse
- #test_lookup_given_nested_keys_looks_up_a_nested_hash_value ⇒ Object
-
#test_lookup_given_nil_as_a_key_returns_nil ⇒ Object
useful because this way we can use the backend with no key for interpolation/pluralization.
Methods included from I18nSimpleBackendTestSetup
#add_datetime_translations, #backend_get_translations, #setup_backend
Instance Method Details
#test_lookup_given_nested_keys_looks_up_a_nested_hash_value ⇒ Object
199 200 201 |
# File 'lib/vendor/i18n/test/simple_backend_test.rb', line 199 def test_lookup_given_nested_keys_looks_up_a_nested_hash_value assert_equal 'bar', @backend.send(:lookup, 'en', :bar, [:foo]) end |
#test_lookup_given_nil_as_a_key_returns_nil ⇒ Object
useful because this way we can use the backend with no key for interpolation/pluralization
195 196 197 |
# File 'lib/vendor/i18n/test/simple_backend_test.rb', line 195 def test_lookup_given_nil_as_a_key_returns_nil assert_nil @backend.send(:lookup, 'en', nil) end |