Пример #1
0
 def test_field_set_flat_name_root(self):
     nested = {'name': 'root_field'}
     schema_reader.field_set_flat_name(nested, '')
     self.assertEqual(nested, {
         'name': 'root_field',
         'flat_name': 'root_field'
     })
Пример #2
0
 def test_field_set_flat_name_nested(self):
     nested = {'name': 'nested'}
     schema_reader.field_set_flat_name(nested, 'parent.')
     self.assertEqual(nested, {
         'name': 'nested',
         'flat_name': 'parent.nested'
     })