Allow file.managed to work with uppercase source_hash in test=true mode

Fixes #48230
This commit is contained in:
rallytime 2018-07-03 10:36:52 -04:00
parent 4c691ac57a
commit a6abf85621
No known key found for this signature in database
GPG key ID: E8F1A4B90D0DEA19

View file

@ -4484,6 +4484,11 @@ def check_managed_changes(
defaults,
skip_verify,
**kwargs)
# Ensure that user-provided hash string is lowercase
if source_sum and ('hsum' in source_sum):
source_sum['hsum'] = source_sum['hsum'].lower()
if comments:
__clean_tmp(sfn)
return False, comments