mirror of
https://github.com/django/django.git
synced 2025-03-29 02:30:48 +00:00
Fixed #21505 -- Added unit test for django.utils.text.get_valid_filename.
This commit is contained in:
parent
101da92ebd
commit
7169722d5c
@ -127,3 +127,7 @@ class TestUtilsText(SimpleTestCase):
|
||||
]
|
||||
for value, output in items:
|
||||
self.assertEqual(text.unescape_entities(value), output)
|
||||
|
||||
def test_get_valid_filename(self):
|
||||
filename = "^&'@{}[],$=!-#()%+~_123.txt"
|
||||
self.assertEqual(text.get_valid_filename(filename), "-_123.txt")
|
||||
|
Loading…
x
Reference in New Issue
Block a user