Avoid circular imports when calling salt.utils functions (#34584)

This commit is contained in:
Nicole Thomas 2016-07-12 13:41:30 -04:00 committed by GitHub
parent 8c72ee56e4
commit 2e1007254b

View File

@ -59,7 +59,6 @@ import salt.output
import salt.version
import salt.utils
import salt.utils.process
from salt.utils import fopen, get_colors
from salt.utils.verify import verify_env
from salt.utils.immutabletypes import freeze
@ -175,7 +174,7 @@ class TestDaemon(object):
def __init__(self, parser):
self.parser = parser
self.colors = get_colors(self.parser.options.no_colors is False)
self.colors = salt.utils.get_colors(self.parser.options.no_colors is False)
def __enter__(self):
'''
@ -709,7 +708,7 @@ class TestDaemon(object):
if self.parser.options.clean is False:
def sumfile(fpath):
# Since we will be doing this for small files, it should be ok
fobj = fopen(fpath)
fobj = salt.utils.fopen(fpath)
m = md5()
while True:
d = fobj.read(8096)