Merge pull request #49239 from Ch3LL/win_yaml_test

Use yaml's safe_dump in windows ec2 tests
This commit is contained in:
Daniel Wozniak 2018-08-22 01:48:12 -07:00 committed by GitHub
commit 0fb9ccf60a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,6 +12,7 @@ import yaml
from salt.config import cloud_providers_config
import salt.utils.cloud
import salt.utils.files
import salt.utils.yaml
# Import Salt Testing Libs
from tests.support.case import ShellCase
@ -121,7 +122,7 @@ class EC2Test(ShellCase):
conf = yaml.safe_load(fp)
conf[name].update(data)
with salt.utils.files.fopen(conf_path, 'w') as fp:
yaml.dump(conf, fp)
salt.utils.yaml.safe_dump(conf, fp)
def copy_file(self, name):
'''