summaryrefslogtreecommitdiffstats
path: root/Lib/test
Commit message (Collapse)AuthorAgeFilesLines
* backport:Guido van Rossum2003-12-031-2/+2
| | | | | | | | Reduce the size of Big String and Big Binary tests to 2**14 (minus one for Big String). This should make the tests pass on Win98SE. Note that the docs only promise lengths up to 2048. Unfortunately this no longer tests for the segfault I was seeing earlier, but I'm confident I've nailed that one. :-) Fixes SF 852281.
* Add testcases for _winreg segfault (SF 851056).Guido van Rossum2003-11-301-1/+3
|
* backport:Anthony Baxter2003-11-301-1/+1
| | | | | Fix a bug discovered by Kalle Svensson: comparing sys.maxint to 2**32-1 makes no sense. Use 2**31-1 instead.
* test_guess_all_types(): Use a more robust test for checking thatBarry Warsaw2003-11-231-4/+7
| | | | | | | | | | guess_all_extensions() returns (at least) what we expect. As Jeff Epler suggests in http://mail.python.org/pipermail/python-dev/2003-September/038264.html We use a set to test the results. This fixes the test when test_urllib2 is run before test_mimetypes.
* Reverted from rev 1.45.6.1 to rev 1.45: deep recursion is still part ofTim Peters2003-11-221-9/+7
| | | | | | | | | | | sre in 2.3, and the backport of the 2.4 version of the tests should not have been done. It got confused because someone else checked a bad change into _sre.c that caused the tests that are *supposed* to raise a recursion exception to stop doing so on some (most?) platforms. test_re passes again on Windows now. Until the bad change to _sre gets fixed, it will fail on platforms other than Windows and FreeBSD, either by "Test Failed", or by bad consequences of C stack overflow.
* SF bug 839548: Bug in type's GC handling causes segfaults.Tim Peters2003-11-201-0/+205
| | | | | | | | Also SF patch 843455. This is a critical bugfix, backported from 2.4 development. I don't intend to backport beyond 2.3 maint. The bugs this fixes have been there since weakrefs were introduced.
* Backport of fix for [ 765456 ]: testAFakeZlib failed on platforms that useJust van Rossum2003-11-181-0/+7
| | | | | a statically linked zlib module, but since the problem it tests can't exist on these systems, simply skip it then.
* subtype_dealloc(): A more complete fix for critical bug 840829 +Tim Peters2003-11-131-0/+19
| | | | | | | | expanded the test case with a piece that needs the more-complete fix. I don't intend to backport this beyond 2.3 maint. It's a critical bugfix, and should be backported to 2.2, 2.1, ..., if more releases in those lines get made.
* Backport of fix for SF bug 840829, memory corruption in some cases ofTim Peters2003-11-131-0/+20
| | | | | | | | weakref callbacks. This is a critical bugfix. It's already been fixed on the trunk (2.4 development). I don't intend to backport it to the 22 line, but if a 2.2.4 ever gets released, this should be in it.
* Overallocate target buffer for normalization more early. Fixes #834676.Martin v. Löwis2003-11-061-0/+3
|
* On RH10, the PIE additions to gcc mean that id() can sometimes be a veryAnthony Baxter2003-11-061-1/+4
| | | | | large 32 bit int, which comes out as a negative int. Workaround this to prevent warnings from the test suite.
* get tests working again. partial backport of 1.46 - I fixed theAnthony Baxter2003-11-041-7/+9
| | | | | | recursive tests that used to fail, but left test_re_groupref_exists disabled, as it fails on the release23-maint branch. Maybe something else needs to be backported?
* Patch #830858: Correct the number of is-functions.Martin v. Löwis2003-10-311-0/+4
|
* Backport checkin:Walter Dörwald2003-10-241-0/+12
| | | | | | | | Fix a bug in the memory reallocation code of PyUnicode_TranslateCharmap(). charmaptranslate_makespace() allocates more memory than required for the next replacement but didn't remember that fact, so memory size was growing exponentially every time a replacement string is longer that one character. This fixes SF bug #828737.
* Patch #813200: Quote executable path on Windows. Fixes #811082.Martin v. Löwis2003-10-231-2/+10
|
* Backport checkin:Walter Dörwald2003-10-204-4/+4
| | | | | Fix a bunch of typos in documentation, docstrings and comments. (From SF patch #810751)
* Revert previous checkin, as it breaks on Unix.Martin v. Löwis2003-10-181-6/+2
|
* Patch #813200: Properly quote executable on Windows. Fixes #811082.Martin v. Löwis2003-10-181-2/+6
|
* SF bug #812202: randint is always evenRaymond Hettinger2003-10-051-0/+32
| | | | | | | | | * Extend rangrange() to return meaningful results when the range is larger than 2**53. Only applies to the MersenneTwister. WichmannHill was left alone in the absence of a proof showing how multiple calls could be combined to produce long bit streams. * WichmannHill was missing from __all__.
* Adopt Christian Stork's suggested argument order for quantifier examples.Raymond Hettinger2003-10-051-11/+11
| | | | Adopt Jeremy Fincher's suggested function name, "any", instead of "some".
* Backport Tim's fix to test_winsound.pyRaymond Hettinger2003-09-221-1/+12
| | | | | | | | PlaySoundTest.test_alias_fallback(): Disabled this test, and explained why in a new comment. My home Win98SE box is one of the "real systems" alluded to (my system "default sound" appears to have vanished sometime in the last month, that's certainly not a Python bug, and the MS PlaySound docs are correct in their explanation of what happens then).
* Backport Tim's fix to SF #809915.Raymond Hettinger2003-09-211-1/+8
| | | | Creates a url that should always be invalid.
* Fix documentation bugs.Raymond Hettinger2003-09-161-73/+158
| | | | | Add support for iterators and other mapping methods. Convert tests to unittest format and expand their coverage.
* Backport addition of the __all__ attribute for unittest.pyRaymond Hettinger2003-09-161-1/+2
|
* **kwds arg was missing from __init__ for Dict{Reader,Writer} classes.Skip Montanaro2003-09-061-0/+7
|
* SF bug #801342: Bug (documentation or real, your choice) in random.sample.Raymond Hettinger2003-09-051-0/+11
| | | | | | | | | | | | random.sample() uses one of two algorithms depending on the ratio of the sample size to the population size. One of the algorithms accepted any iterable population argument so long as it defined __len__(). The other had a stronger requirement that the population argument be indexable. While it met the documentation specifications which insisted that the population argument be a sequence, it made random.sample() less usable with sets. So, the second algorithm was modified to coerce non-indexable iterables and dictionaries into a tuple before proceeding.
* Only apply case-insensitivity test on appropriate platforms.' test_filecmp.pyRaymond Hettinger2003-09-021-2/+6
|
* SF bug #453515: filecmp.dircmp case sensitivity bugRaymond Hettinger2003-09-021-2/+6
|
* Fix failing testRaymond Hettinger2003-09-021-1/+1
|
* SF bug #785222: zlib monotonic testRaymond Hettinger2003-08-311-11/+0
| | | | | | For smaller datasets, it is not always true the increasing the compression level always results in better compression. Removed the test which made this invalid assumption.
* * Add news item for the previous bugfixRaymond Hettinger2003-08-301-4/+13
| | | | * Backport itertoolsmodule.c 1.19 to re-sync Py2.3.1 with Py2.4.
* SF bug 797650: Infinite loop in textwrap.pyRaymond Hettinger2003-08-301-0/+10
| | | | | | When the indents were set to longer than the width and long word breaking was enabled, an infinite loop would result because the inner loop did not assure that at least one character was stripped off on every pass.
* SF bug #793826: using itertools.izip to mutate tuplesRaymond Hettinger2003-08-291-1/+32
| | | | Avoid Armin Rigo's dastardly exercise in re-entrancy.
* _strptime.srptime() escaped parentheses in the format string properly.Brett Cannon2003-08-291-0/+9
| | | | Closes bug #796149 .
* SF bug #795506: Wrong handling of string format code for float values.Raymond Hettinger2003-08-271-0/+1
| | | | Added missing support for '%F' as had been documented.
* test_largefile can leave its temp file open if one of many tests fail. OnJason Tishler2003-08-261-73/+81
| | | | | | | | | | | | | | | | | | | | platforms (e.g., Cygwin) that are "particular" about open files, this will cause other regression tests that use the same temp file to fail: $ ./python.exe -E -tt Lib/test/regrtest.py -l test_largefile test_mmap test_mutants test_largefile test test_largefile failed -- got -1794967295L, but expected 2500000001L test_mmap test test_mmap crashed -- exceptions.IOError: [Errno 13] Permission denied: '@test' test_mutants test test_mutants crashed -- exceptions.IOError: [Errno 13] Permission denied: '@test' This patch solves the problem by adding missing "try/finally" blocks. Note that the "large" size of this patch is due to many white space changes -- otherwise, the patch is small. I tested this patch under Red Hat Linux 8.0 too.
* Backport improvements to set.py so that the interface will remainRaymond Hettinger2003-08-171-16/+138
| | | | | | | | | | | | | | | | | | consistent across versions. * Relaxed the argument restrictions for non-operator methods. They now allow any iterable instead of requiring a set. This makes the module a little easier to use and paves the way for an efficient C implementation which can take better advantage of iterable arguments while screening out immutables. * Added a PendingDeprecationWarning for Set.update() because it now duplicates Set.union_update() * Adapted the tests and docs to include the above changes. * Added more test coverage including testing identities and checking to make sure non-restartable generators work as arguments.
* Backport checkin:Walter Dörwald2003-08-151-4/+4
| | | | | | | Make a copy of L before appending, so the global L remains unchanged (and sys.gettotalrefcount() remains constant). Fix a few typos.
* Backport checkins:Walter Dörwald2003-08-121-3/+35
| | | | | | | | * Enhance message for UnicodeEncodeError and UnicodeTranslateError. If there is only one bad character it will now be printed in a form that is a valid Python string. * Add a unicode prefix to the characters in the UnicodeEncodeError and UnicodeTranslateError message.
* Unconditionally opening the temp file in text mode causes this test to failJason Tishler2003-08-111-2/+5
| | | | | | under Cygwin. The attached patch corrects this problem. I tested this patch under Red Hat Linux 8.0 too.
* Fix bug where handling issue of time.tzname[0] == time.tzname[1] andBrett Cannon2003-08-111-0/+23
| | | | | | time.daylight were all true. Add an explicit test for this issue. Closes bug #783952 .
* SF bug #778964: bad seed in python 2.3 randomRaymond Hettinger2003-08-091-1/+1
| | | | | | | The default seed is time.time(). Multiplied by 256 before truncating so that fractional seconds are used. This way, two consequetive calls to random.seed() are much more likely to produce different sequences.
* SF bug #770485: cStringIO does not set closed attrRaymond Hettinger2003-08-081-0/+10
|
* As penance for forgetting to flag my last checkins as bugfix candidates,Michael W. Hudson2003-08-071-0/+7
| | | | | | just do the backport. These changes do not apply to release22-maint.
* Re-introduction of caching. Not thread-safe against the changing of localeBrett Cannon2003-08-061-0/+41
| | | | | in the middle of executing time.strptime . Added new tests for caching mechanism; taken from 2.4 branch and tweaked appropriately.
* Demonstrate and fix [ 783882 ] os.lstat crashes with Unicode filename.Mark Hammond2003-08-061-0/+2
| | | | Also checked in on trunk.
* Remove __floordiv__ test, as it's deprecated.Walter Dörwald2003-08-051-4/+0
|
* Backport:Walter Dörwald2003-08-051-0/+12
| | | | | | * Check both __div__ and __truediv__ in division tests. (From SF patch #543867) * Remove useless import.
* Support trailing dots in DNS names. Fixes #782510.Martin v. Löwis2003-08-051-0/+4
|
* Correct URL for normalization file. Fixes #781065.Martin v. Löwis2003-08-051-2/+2
|