Commit Graph

7 Commits

Author SHA1 Message Date
Erik Johnson
002aa88a97
Replace yaml usage with a helper to ensure unicode is handled properly
Without allow_unicode=True, unicode characters are processed through the
str representer and on Python 2 are dumped as a Unicode code point (i.e.
a literal \u0414). This commit makes allow_unicode=True the default in
our salt.utils.yamlloader.safe_dump() helper. It also adds a new
salt.utils.yamlloader.dump() helper which wraps yaml.dump() and also
makes allow_unicode=True the default.

To make importing and using our custom yaml loader/dumper easier, a
convenience module called salt.utils.yaml has been added, which does a
wildcard import from both salt.utils.yamldumper and
salt.utils.yamlloader.

Refs to yaml.load/dump and yaml.safe_load/safe_dump have been updated to
salt.utils.yaml, to ensure that unicode is handled properly.
2018-01-03 14:14:21 -06:00
Daniel Wallace
d0586013eb
fix pylint 2017-12-21 10:40:54 -07:00
Daniel Wallace
59e2e56d13
chmod the xml files before trying to copy 2017-12-21 08:17:10 -07:00
Daniel Wallace
a5c1410e23
catch IOError when copying xml files back 2017-12-20 18:26:18 -07:00
rallytime
8237f45a46
Add print_function to __future__ import list 2017-10-25 14:54:03 -04:00
Daniel Wallace
56a3ad8f68
fix pylint comments 2017-10-24 12:18:27 -06:00
Daniel Wallace
4add666db1
add comment to Gemfile and move copyartifacts
moved copyartifacts.py to tests/support

Also added a comment to the Gemfile that this is only used to run the testsuite with kitchen-salt
2017-10-24 12:01:57 -06:00