3 class LanguageTest < ActiveSupport::TestCase
5 create(:language, :code => "sl", :english_name => "Slovenian", :native_name => "slovenščina")
6 assert_equal "Slovenian (slovenščina)", Language.find("sl").name
9 def test_same_native_name
10 create(:language, :code => "af", :english_name => "Afrikaans", :native_name => "Afrikaans")
11 assert_equal "Afrikaans", Language.find("af").name
15 assert_equal 0, Language.count
16 assert_raise ActiveRecord::RecordNotFound do
20 Language.load("config/languages.yml")
22 assert_equal 197, Language.count
23 assert_not_nil Language.find("zh")