diff options
author | Anthon van der Neut <anthon@mnt.org> | 2019-01-16 08:14:14 +0100 |
---|---|---|
committer | Anthon van der Neut <anthon@mnt.org> | 2019-01-16 08:14:14 +0100 |
commit | 713d6c65fd545c6ad38d73686cfb040fd6dc217d (patch) | |
tree | b86dd2a676dd50ea30311d163bcfb7614c36078f /_test | |
parent | df566d79c442daceb169454a1003c39e9e71b325 (diff) | |
download | ruamel.yaml-713d6c65fd545c6ad38d73686cfb040fd6dc217d.tar.gz |
insert merge key in old (absolute) position0.15.86
Diffstat (limited to '_test')
-rw-r--r-- | _test/test_z_data.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/_test/test_z_data.py b/_test/test_z_data.py index ca75ca6..99810aa 100644 --- a/_test/test_z_data.py +++ b/_test/test_z_data.py @@ -9,6 +9,7 @@ import warnings # NOQA from ruamel.std.pathlib import Path base_path = Path('data') # that is ruamel.yaml.data +PY2 = sys.version_info[0] == 2 class YAMLData(object): @@ -124,7 +125,10 @@ class TestYAMLData(object): buf = StringIO() yaml.dump(data, buf) expected = input.value if output is None else output.value - assert buf.getvalue() == expected + value = buf.getvalue() + if PY2: + value = value.decode('utf-8') + assert value == expected def load_assert(self, input, confirm, yaml_version=None): from ruamel.yaml.compat import Mapping |