summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_re.py
Commit message (Collapse)AuthorAgeFilesLines
* [2.7] bpo-30363: Backport warnings in the re module. (#1577)Serhiy Storchaka2017-05-181-14/+78
| | | | | | Running Python with the -3 option now warns about regular expression syntax that is invalid or has different semantic in Python 3 or will change the behavior in future Python versions.
* Backported tests for issue #28070.Serhiy Storchaka2016-09-101-0/+3
|
* Issues #814253, #9179: Warnings now are raised when group references andSerhiy Storchaka2015-02-211-4/+41
| | | | | conditional group references are used in lookbehind assertions in regular expressions.
* backout fac649bf2d10 (#9179) for further considerationBenjamin Peterson2014-11-301-37/+1
|
* Issue #12728: Different Unicode characters having the same uppercase butSerhiy Storchaka2014-11-101-0/+45
| | | | different lowercase are now matched in case-insensitive regular expressions.
* Issues #814253, #9179: Group references and conditional group references nowSerhiy Storchaka2014-11-071-1/+37
| | | | work in lookbehind assertions in regular expressions.
* Issue #17381: Fixed ranges handling in case-insensitive regular expressions.Serhiy Storchaka2014-10-311-0/+37
|
* Issue #22410: Module level functions in the re module now cache compiledSerhiy Storchaka2014-10-301-0/+37
| | | | locale-dependent regular expressions taking into account the locale.
* allow longs as indexes to group() (closes #22530)Benjamin Peterson2014-10-011-0/+4
|
* Issue #22423: Fixed debugging output of the GROUPREF_EXISTS opcode in the reSerhiy Storchaka2014-09-211-6/+23
| | | | module.
* Test re pickling for all protocols.Serhiy Storchaka2014-09-151-3/+6
|
* Now re tests work again on Unicode-disabled build.Serhiy Storchaka2014-09-141-47/+52
| | | | Simplified existing detections of Unicode-disabled build.
* Use more appropriate asserts in re tests.Serhiy Storchaka2014-09-141-59/+59
|
* Issue #20283: RE pattern methods now accept the string keyword parametersSerhiy Storchaka2014-03-061-0/+13
| | | | | as documented. The pattern and source keyword parameters are left as deprecated aliases.
* Issue #20426: When passing the re.DEBUG flag, re.compile() displays the ↵Antoine Pitrou2014-02-031-0/+14
| | | | debug output every time it is called, regardless of the compilation cache.
* Issue #19572: More silently skipped tests explicitly skipped.Zachary Ware2013-12-101-3/+3
|
* Issue #19327: Fixed the working of regular expressions with too big charset.Serhiy Storchaka2013-10-241-0/+2
|
* Issue #2537: Remove breaked check which prevented valid regular expressions.Serhiy Storchaka2013-08-191-0/+10
| | | | | | Patch by Meador Inge. See also issue #18647.
* Issue #17998: Fix an internal error in regular expression engine.Serhiy Storchaka2013-08-031-0/+10
|
* #17341: Include name in re error message about invalid group name.R David Murray2013-04-141-0/+11
| | | | Patch by Jason Michalski.
* Issue #9669: Protect re against infinite loops on zero-width matching inSerhiy Storchaka2013-02-161-0/+9
| | | | non-greedy repeat. Patch by Matthew Barnett.
* Issue #13169: The maximal repetition number in a regular expression has beenSerhiy Storchaka2013-02-161-1/+32
| | | | | increased from 65534 to 2147483647 (on 32-bit platform) or 4294967294 (on 64-bit).
* #13899: \A, \Z, and \B now correctly match the A, Z, and B literals when ↵Ezio Melotti2013-01-111-0/+6
| | | | used inside character classes (e.g. [A]). Patch by Matthew Barnett.
* Fix test splitting in previous commit.Antoine Pitrou2012-12-031-4/+2
|
* Split the bigmem re test in two separate tests with different memory ↵Antoine Pitrou2012-12-031-2/+10
| | | | requirements.
* Issue #10182: The re module doesn't truncate indices to 32 bits anymore.Antoine Pitrou2012-12-021-0/+16
| | | | Patch by Serhiy Storchaka.
* Issue #1160: Fix compiling large regular expressions on UCS2 builds.Antoine Pitrou2012-11-201-0/+6
| | | | Patch by Serhiy Storchaka.
* #12759: sre_parse now raises a proper error when the name of the group is ↵Ezio Melotti2012-11-031-0/+20
| | | | missing. Initial patch by Serhiy Storchaka.
* #14179: add tests for re.compile. Patch by Florian Mladitsch.Ezio Melotti2012-03-121-0/+10
|
* #10713: Improve documentation for \b and \B and add a few tests. Initial ↵Ezio Melotti2012-02-291-0/+26
| | | | patch and tests by Martin Pool.
* #2650: Refactor re.escape and its tests.Ezio Melotti2011-03-251-11/+57
|
* #11515: fix several typos. Patch by Piotr Kasprzyk.Ezio Melotti2011-03-151-1/+1
|
* Replace catch_warnings with check_warnings when it makes sense. Use ↵Florent Xicluna2010-03-311-6/+3
| | | | assertRaises context manager to simplify some tests.
* Remove unused imports in test modules.Georg Brandl2010-02-071-2/+2
|
* Increased the overflow value on test_dealloc to make sure that it is big ↵Ezio Melotti2010-01-231-1/+5
| | | | enough even for wide builds.
* Issue #3299: Fix possible crash in the _sre module when given badAntoine Pitrou2010-01-141-0/+6
| | | | argument values in debug mode. Patch by Victor Stinner.
* don't need to mess up sys.pathBenjamin Peterson2009-10-151-3/+0
|
* Issue #6561: '\d' regular expression should not match characters ofMark Dickinson2009-07-281-0/+21
| | | | | category [No]; only those of category [Nd]. (Backport of r74237 from py3k.)
* convert usage of fail* to assert*Benjamin Peterson2009-06-301-1/+1
|
* - Issue #3629: Fix sre "bytecode" validator for an end case.Guido van Rossum2008-09-101-0/+4
| | | | Reviewed by Amaury.
* warnings.catch_warnings() now returns a list or None instead of the customBrett Cannon2008-09-091-2/+2
| | | | | | | | WarningsRecorder object. This makes the API simpler to use as no special object must be learned. Closes issue 3781. Review by Benjamin Peterson.
* #3654: fix duplicate test method name. Review by Benjamin P.Georg Brandl2008-08-241-4/+2
|
* Closing issue1761.Amaury Forgeot d'Arc2008-01-101-0/+12
| | | | | | | | | | | | Surprising behaviour of the "$" regexp: it matches the end of the string, AND just before the newline at the end of the string:: re.sub('$', '#', 'foo\n') == 'foo#\n#' Python is consistent with Perl and the pcre library, so we just document it. Guido prefers "\Z" to match only the end of the string.
* Issue #1700, reported by Nguyen Quan Son, fix by Fredruk Lundh:Guido van Rossum2008-01-031-0/+30
| | | | | Regular Expression inline flags not handled correctly for some unicode characters. (Forward port from 2.5.2.)
* Fix issue 1661: Flags argument silently ignored in re functions with ↵Raymond Hettinger2007-12-191-0/+8
| | | | compiled regexes.
* Patch # 1140 (my code, approved by Effbot).Guido van Rossum2007-09-101-0/+25
| | | | | | | | | Make sure the type of the return value of re.sub(x, y, z) is the type of y+x (i.e. unicode if either is unicode, str if they are both str) even if there are no substitutions or if x==z (which triggered various special cases in join_list()). Could be backported to 2.5; no need to port to 3.0.
* Remove test.test_support.guard_warnings_filter.Brett Cannon2007-08-141-2/+2
| | | | | | | | test.test_support.catch_warning is more full-featured and provides the same functionality. Since guard_warnings_filter was added in 2.6 there is no backwards-compatibility issues.
* Whitespace normalization. Ugh, we really need to do this more often.Neal Norwitz2007-04-251-1/+1
| | | | You might want to review this change as it's my first time. Be gentle. :-)
* Array module's buffer interface can now handle empty arrays.Raymond Hettinger2007-04-021-0/+7
|
* Bug #1675967: re patterns pickled with older Python versions canŽiga Seilnacht2007-03-211-1/+7
| | | | now be unpickled. Will backport.