You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
718 B

9 years ago
9 years ago
  1. # '''
  2. # Created on Jan 25, 2014
  3. #
  4. # @author: Chris
  5. # '''
  6. #
  7. # import unittest
  8. #
  9. # import i18n
  10. #
  11. #
  12. # class Test(unittest.TestCase):
  13. #
  14. # def test_i18n_loads_module_by_name(self):
  15. # self.assertTrue(i18n._DICTIONARY is None)
  16. #
  17. # i18n.load('english')
  18. # self.assertTrue(i18n._DICTIONARY is not None)
  19. # self.assertEqual('Cancel', i18n._('cancel'))
  20. #
  21. # i18n.load('french')
  22. # self.assertEqual('Annuler', i18n._('cancel'))
  23. #
  24. #
  25. # def test_i18n_throws_exception_on_no_lang_file_found(self):
  26. # self.assertRaises(IOError, i18n.load, 'chionenglish')
  27. #
  28. #
  29. #
  30. #
  31. #
  32. # if __name__ == "__main__":
  33. # pass
  34. # #import sys;sys.argv = ['', 'Test.testName']
  35. # unittest.main()