From 337cd652a5f7d7fcbc6c413d11f8bac1f87379d0 Mon Sep 17 00:00:00 2001 From: Jacob Walls Date: Thu, 25 Feb 2021 18:40:18 -0500 Subject: Fixed #28607 -- Prevented duplicates in HashedFilesMixin post-processing results. Thanks Ed Morley for the implementation idea. --- tests/staticfiles_tests/test_storage.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'tests') diff --git a/tests/staticfiles_tests/test_storage.py b/tests/staticfiles_tests/test_storage.py index dc45a0b839..7ae88e6c68 100644 --- a/tests/staticfiles_tests/test_storage.py +++ b/tests/staticfiles_tests/test_storage.py @@ -203,6 +203,8 @@ class TestHashedFiles: self.assertIn(os.path.join('cached', 'css', 'window.css'), stats['post_processed']) self.assertIn(os.path.join('cached', 'css', 'img', 'window.png'), stats['unmodified']) self.assertIn(os.path.join('test', 'nonascii.css'), stats['post_processed']) + # No file should be yielded twice. + self.assertCountEqual(stats['post_processed'], set(stats['post_processed'])) self.assertPostCondition() def test_css_import_case_insensitive(self): -- cgit v1.3