Fix failing py3 tests

This should fix the following integration tests
integration.states.test_file.FileTest.test_directory_clean_require_in
integration.states.test_file.FileTest.test_directory_clean_require_in_with_id
integration.states.test_file.FileTest.test_directory_clean_require_with_name
integration.states.test_file.FileTest.test_recurse_clean
integration.states.test_file.FileTest.test_recurse_clean_specific_env
This commit is contained in:
twangboy 2019-02-22 11:59:57 -07:00
parent feb29f3353
commit 6b0b5d2af1
No known key found for this signature in database
GPG Key ID: 93FF3BDEB278C9EB

View File

@ -633,6 +633,7 @@ def _clean_dir(root, keep, exclude_pat):
Clean out all of the files and directories in a directory (root) while
preserving the files in a list (keep) and part of exclude_pat
'''
root = os.path.normcase(root)
real_keep = _find_keep_files(root, keep)
removed = set()