summaryrefslogtreecommitdiff
path: root/tests/utils_tests/test_text.py
AgeCommit message (Collapse)Author
2018-08-21Fixed #29654 -- Made text truncation an ellipsis character instead of three ↵Claude Paroz
dots. Thanks Sudhanshu Mishra for the initial patch and Tim Graham for the review.
2018-07-20Fixed #29412 -- Stopped marking slugify() result as HTML safe.Claude Paroz
2018-03-06Fixed CVE-2018-7537 -- Fixed catastrophic backtracking in ↵Tim Graham
django.utils.text.Truncator. Thanks James Davis for suggesting the fix.
2017-04-04Updated tests after French translation updateClaude Paroz
2017-03-04Refs #27795 -- Removed unneeded force_text callsClaude Paroz
Thanks Tim Graham for the review.
2017-02-09Refs #23919 -- Removed default 'utf-8' argument for str.encode()/decode().Tim Graham
2017-02-07Converted usage of ugettext* functions to their gettext* aliasesClaude Paroz
Thanks Tim Graham for the review.
2017-01-18Refs #23919 -- Removed six.<various>_types usageClaude Paroz
Thanks Tim Graham and Simon Charette for the reviews.
2017-01-18Refs #23919 -- Removed encoding preambles and future importsClaude Paroz
2016-11-10Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings.za
2016-08-24Fixed #26866 -- Added format_lazy functionMattias Loverot
Added format_lazy function to django.utils.text module. Useful when dealing with relative complex lazy string concatenations (e.g. in urls.py when translating urls in regular expressions).
2016-04-08Fixed E128 flake8 warnings in tests/.Tim Graham
2015-12-12Fixed #20223 -- Added keep_lazy() as a replacement for allow_lazy().Iacopo Spalletti
Thanks to bmispelon and uruz for the initial patch.
2015-07-17Fixed #16501 -- Added an allow_unicode parameter to SlugField.Edward Henderson
Thanks Flavio Curella and Berker Peksag for the initial patch.
2015-02-04Fixed #24242 -- Improved efficiency of utils.text.compress_sequence()Matthew Somerville
The function no longer flushes zfile after each write as doing so can lead to the gzipped streamed content being larger than the original content; each flush adds a 5/6 byte type 0 block. Removing this means buf.read() may return nothing, so only yield if that has some data. Testing shows without the flush() the buffer is being flushed every 17k or so and compresses the same as if it had been done as a whole string.
2015-01-17Removed utils.text.javascript_quote() per deprecation timeline; refs #21725.Tim Graham
2014-12-30Applied ignore_warnings to Django testsClaude Paroz
2014-12-06Refs #23947 -- Worked around a bug in Python that prevents deprecation ↵Diego Guimarães
warnings from appearing in tests.
2014-09-23Consolidated some text utils into the utils_tests test package.Loic Bistuer
2014-03-08Fixed #21188 -- Introduced subclasses for to-be-removed-in-django-XX warningsClaude Paroz
Thanks Anssi Kääriäinen for the idea and Simon Charette for the review.
2014-03-05Really hidden warnings in javascript_quote testsClaude Paroz
Refs #21725.
2014-02-22Deprecated django.utils.text.javascript_quote.Baptiste Mispelon
Refs #21725.
2014-02-22Fixed test failures when running in a narrow Python build.Baptiste Mispelon
2014-02-15Fixed #21725 -- Fixed JavaScript quoting encoding.MattBlack85
Thanks to nedbatchelder for the report.
2014-02-06Fixed #21731 -- Made javascript_quote escapes '</'.Vajrasky Kok
2013-12-12Fixed #21574 -- Handle bytes consistently in utils.text.normalize_newlines.Baptiste Mispelon
All input is now coerced to text before being normalized. This changes nothing under Python 2 but it allows bytes to be passed to the function without a TypeError under Python3 (bytes are assumed to be utf-8 encoded text). Thanks to trac user vajrasky for the report.
2013-12-07Fixed #21572 -- Added unit test for django.utils.text.normalize_newlines.Vajrasky Kok
2013-11-24Fixed #21505 -- Added unit test for django.utils.text.get_valid_filename.Vajrasky Kok
2013-11-02Fixing E302 ErrorsJason Myers
Signed-off-by: Jason Myers <jason@jasonamyers.com>
2013-11-02Fixed #21302 -- Fixed unused imports and import *.Tim Graham
2013-10-14Fixed #21266 -- Fixed E201,E202 pep8 warnings.Larry O'Neill
2013-10-08Fixed #20568 -- truncatewords_html no longer splits words containing HTML ↵Jaap Roes
entities. Thanks yann0 at hotmail.com for the report.
2013-09-27Fix #21185: Added tests for unescape_entities.Baptiste Mispelon
Also fixed a py3 incompatibility. Thanks to brutasse for the report.
2013-04-12Modified utils_tests for unittest2 discovery.Preston Timmons