From ef2403b616c3ee2c67ea2cca08d4bc79d1e94885 Mon Sep 17 00:00:00 2001 From: Jono Yang Date: Tue, 7 May 2024 19:03:53 -0700 Subject: [PATCH] Normalize instances of UTF to Unicode Signed-off-by: Jono Yang --- src/scancode/cli_test_utils.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/scancode/cli_test_utils.py b/src/scancode/cli_test_utils.py index 8a2c404cb5a..b8fec48194e 100644 --- a/src/scancode/cli_test_utils.py +++ b/src/scancode/cli_test_utils.py @@ -335,6 +335,8 @@ def streamline_scanned_file(scanned_file, remove_file_date=False, normalize_file if normalize_file_type and (file_type := scanned_file.get('file_type')): file_type_segments = file_type.split() normalized_file_type = file_type_segments[0] + if 'UTF' in normalized_file_type: + normalized_file_type = 'Unicode' scanned_file['file_type'] = normalized_file_type