| Class | I18nSimpleBackendTranslationsTest |
| In: |
vendor/rails/activesupport/lib/active_support/vendor/i18n-0.1.3/test/simple_backend_test.rb
|
| Parent: | Test::Unit::TestCase |
# File vendor/rails/activesupport/lib/active_support/vendor/i18n-0.1.3/test/simple_backend_test.rb, line 103
103: def test_store_translations_adds_translations # no, really :-)
104: @backend.store_translations 'en''en', :foo => 'bar'
105: assert_equal Hash['en''en', {:foo => 'bar'}], backend_get_translations
106: end
# File vendor/rails/activesupport/lib/active_support/vendor/i18n-0.1.3/test/simple_backend_test.rb, line 119
119: def test_store_translations_converts_keys_to_symbols
120: # backend_reset_translations!
121: @backend.store_translations 'en', 'foo' => {'bar' => 'bar', 'baz' => 'baz'}
122: assert_equal Hash['en''en', {:foo => {:bar => 'bar', :baz => 'baz'}}], backend_get_translations
123: end
# File vendor/rails/activesupport/lib/active_support/vendor/i18n-0.1.3/test/simple_backend_test.rb, line 108
108: def test_store_translations_deep_merges_translations
109: @backend.store_translations 'en''en', :foo => {:bar => 'bar'}
110: @backend.store_translations 'en''en', :foo => {:baz => 'baz'}
111: assert_equal Hash['en''en', {:foo => {:bar => 'bar', :baz => 'baz'}}], backend_get_translations
112: end
# File vendor/rails/activesupport/lib/active_support/vendor/i18n-0.1.3/test/simple_backend_test.rb, line 114
114: def test_store_translations_forces_locale_to_sym
115: @backend.store_translations 'en', :foo => 'bar'
116: assert_equal Hash['en''en', {:foo => 'bar'}], backend_get_translations
117: end