コード例 #1
0
ファイル: test_catalog.py プロジェクト: vlegoff/ytranslate
 def test_write_dictionary(self):
     """Test to read and retrive the nested structure."""
     catalog = Catalog("test")
     catalog.read_YAML(SIMPLE_DOC)
     dictionary = catalog.write_dictionary()
     self.assertEqual(dictionary, {
         'file': u'Fichier',
         'edit': u'Édition',
         'view': u'Affichage',
         'greeting': 'Bienvenue, {name} !',
         'connection': {
             'connected': u'Connecté',
             'connecting': u'Connexion en cours',
             'error': u'Connexion impossible',
         },
     })