mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Add test for custom YAML loader with unicode literal strings
This commit is contained in:
parent
a0118bcece
commit
9d8486a894
1 changed files with 12 additions and 0 deletions
|
@ -100,3 +100,15 @@ class YamlLoaderTestCase(TestCase):
|
|||
<<: *p1
|
||||
v2: beta
|
||||
v2: betabeta'''))
|
||||
|
||||
def test_yaml_with_unicode_literals(self):
|
||||
'''
|
||||
Test proper loading of unicode literals
|
||||
'''
|
||||
self.assertEqual(
|
||||
self._render_yaml(textwrap.dedent('''\
|
||||
foo:
|
||||
a: Д
|
||||
b: {'a': u'\\u0414'}''')),
|
||||
{'foo': {'a': u'\u0414', 'b': {'a': u'\u0414'}}}
|
||||
)
|
||||
|
|
Loading…
Add table
Reference in a new issue