Update old utils paths with new paths

This commit is contained in:
rallytime 2018-08-14 09:52:40 -04:00
parent 49c2a784bb
commit 4649f60209
No known key found for this signature in database
GPG Key ID: E8F1A4B90D0DEA19

View File

@ -363,7 +363,7 @@ class FileTest(ModuleCase, SaltReturnAssertsMixin):
with salt.utils.files.fopen(grain_path, 'r') as fp_:
file_contents = fp_.readlines()
if salt.utils.is_windows():
if salt.utils.platform.is_windows():
match = '^minion\r\n'
else:
match = '^minion\n'
@ -592,7 +592,7 @@ class FileTest(ModuleCase, SaltReturnAssertsMixin):
name = os.path.join(TMP, 'local_source_with_source_hash')
local_path = os.path.join(BASE_FILES, 'grail', 'scene33')
actual_hash = '567fd840bf1548edc35c48eb66cdd78bfdfcccff'
if salt.utils.is_windows():
if salt.utils.platform.is_windows():
# CRLF vs LF causes a differnt hash on windows
actual_hash = 'f658a0ec121d9c17088795afcc6ff3c43cb9842a'
# Reverse the actual hash
@ -677,7 +677,7 @@ class FileTest(ModuleCase, SaltReturnAssertsMixin):
'-{0}_|-managed'.format(name)
local_path = os.path.join(BASE_FILES, 'hello_world.txt')
actual_hash = 'c98c24b677eff44860afea6f493bbaec5bb1c4cbb209c6fc2bbb47f66ff2ad31'
if salt.utils.is_windows():
if salt.utils.platform.is_windows():
# CRLF vs LF causes a differnt hash on windows
actual_hash = '92b772380a3f8e27a93e57e6deeca6c01da07f5aadce78bb2fbb20de10a66925'
uppercase_hash = actual_hash.upper()
@ -3703,7 +3703,7 @@ class RemoteFileTest(ModuleCase, SaltReturnAssertsMixin):
cls.webserver = Webserver()
cls.webserver.start()
cls.source = cls.webserver.url('grail/scene33')
if salt.utils.is_windows():
if salt.utils.platform.is_windows():
# CRLF vs LF causes a differnt hash on windows
cls.source_hash = '21438b3d5fd2c0028bcab92f7824dc69'
else: