Commit graph

17445 commits

Author SHA1 Message Date
Ezio Melotti
b08495bbcf #17198: Fix a NameError in the dbm module. Patch by Valentina Mukhamedzhanova. 2013-07-07 13:15:08 +02:00
Florent Xicluna
74a146d3ac Merge #18013: Fix cgi.FieldStorage to parse the W3C sample form. 2013-07-07 12:46:28 +02:00
Florent Xicluna
331c3fd874 Issue #18013: Fix cgi.FieldStorage to parse the W3C sample form. 2013-07-07 12:44:28 +02:00
Brett Cannon
7e5d55705c merge for issue #18351. 2013-07-06 18:04:41 -04:00
Brett Cannon
a53cca3fea Issue #18351: Fix various issues with
importlib._bootstrap._get_sourcefile().

Thanks to its only use by the C API, it was never properly tested
until now.

Thanks to Neal Norwitz for discovering the bug and Madison May for the patch.
2013-07-06 17:56:43 -04:00
Ezio Melotti
e0a39de647 #18380: merge with 3.3. 2013-07-06 17:17:45 +02:00
Ezio Melotti
2a99d5df63 #18380: pass regex flags to the right argument. Patch by Valentina Mukhamedzhanova. 2013-07-06 17:16:04 +02:00
Florent Xicluna
c2464bf5c6 test_ftplib: silence a BytesWarning when checking TypeError 2013-07-06 15:08:29 +02:00
Florent Xicluna
5f3fef37f6 test_ftplib: silence a BytesWarning when checking TypeError 2013-07-06 15:08:21 +02:00
Florent Xicluna
8624ed502f Issue #18375: merge with 3.3 2013-07-06 12:27:50 +02:00
Florent Xicluna
d9e7c86d7e Issue #18375: Assume --randomize when --randseed is used for running the testsuite. 2013-07-06 12:25:52 +02:00
Raymond Hettinger
de68e0cf0e Speed-up deque indexing by changing the deque block length to a power of two.
The division and modulo calculation in deque_item() can be compiled
to fast bitwise operations when the BLOCKLEN is a power of two.

Timing before:

 ~/cpython $ py -m timeit -r7 -s 'from collections import deque' -s 'd=deque(range(10))' 'd[5]'
10000000 loops, best of 7: 0.0627 usec per loop

Timing after:

~/cpython $ py -m timeit -r7 -s 'from collections import deque' -s 'd=deque(range(10))' 'd[5]'
10000000 loops, best of 7: 0.0581 usec per loop
2013-07-05 18:05:29 -10:00
Christian Heimes
6597aa16b6 Issue #18347: ElementTree's html serializer now preserves the case of closing tags. 2013-07-05 01:40:52 +02:00
Christian Heimes
54ad7e39df Issue #18347: ElementTree's html serializer now preserves the case of closing tags. 2013-07-05 01:39:49 +02:00
Brett Cannon
260fbe80c5 Issue #15767: Excise the remaining instances of ModuleNotFoundError 2013-07-04 18:16:15 -04:00
Brett Cannon
3dfd23245b Remove dead code in test_exceptions. 2013-07-04 18:04:20 -04:00
Brett Cannon
fc4b5b9a42 Move test_import over to unittest.main(). 2013-07-04 18:03:57 -04:00
Brett Cannon
679ecb565b Issue #15767: back out 8a0ed9f63c6e, finishing the removal of
ModuleNotFoundError.
2013-07-04 17:51:50 -04:00
Brett Cannon
45091c0a0c Issue #15767: Back out 8d28d44f3a9a related to ModuleNotFoundError. 2013-07-04 17:44:08 -04:00
Antoine Pitrou
0cb1e9ab97 Issue #11185: Fix test_wait4 under AIX. Patch by Sébastien Sablé. 2013-07-04 21:05:30 +02:00
Antoine Pitrou
be9c841494 Issue #11185: Fix test_wait4 under AIX. Patch by Sébastien Sablé. 2013-07-04 21:03:10 +02:00
Victor Stinner
7e71c5672c (Merge 3.3) test_time.test_monotonic(): use a longer sleep to try to make the test more reliable 2013-07-03 23:07:59 +02:00
Victor Stinner
a9c99a6119 test_time.test_monotonic(): use a longer sleep to try to make the test more reliable 2013-07-03 23:07:37 +02:00
Victor Stinner
647d1e1acd (Merge 3.3) test_faulthandler: skip test_read_null() on AIX
AIX maps the first page of memory at address zero as valid, read-only.  Reading
NULL is not a fault on AIX. This is utilized by IBM compiler optimizations.
One speculatively can indirect through a pointer which may be null without
first testing if null and defer the test before using the value.
2013-07-03 22:35:39 +02:00
Victor Stinner
330426cfe2 test_faulthandler: skip test_read_null() on AIX
AIX maps the first page of memory at address zero as valid, read-only.  Reading
NULL is not a fault on AIX. This is utilized by IBM compiler optimizations.
One speculatively can indirect through a pointer which may be null without
first testing if null and defer the test before using the value.
2013-07-03 22:29:42 +02:00
Christian Heimes
3126a3d156 Issue #18339: use with self.assertRaises() to make test case more readable 2013-07-01 23:00:22 +02:00
Christian Heimes
2178248858 Issue #18339: use with self.assertRaises() to make test case more readable 2013-07-01 23:00:13 +02:00
Richard Oudkerk
626032ac54 Issue #17097: Merge. 2013-07-01 19:10:39 +01:00
Richard Oudkerk
cca8c53d6a Issue #17097: Make multiprocessing ignore EINTR. 2013-07-01 18:59:26 +01:00
Łukasz Langa
7c1457bed2 Merge with current default 2013-07-01 16:03:17 +02:00
Łukasz Langa
3720c77e30 Issue #18244: Adopt C3-based linearization in functools.singledispatch for improved ABC support 2013-07-01 16:00:38 +02:00
Christian Heimes
bfafab1849 Issue #18339: Negative ints keys in unpickler.memo dict no longer cause a
segfault inside the _pickle C extension.
2013-07-01 15:18:49 +02:00
Christian Heimes
a24b4d260b Issue #18339: Negative ints keys in unpickler.memo dict no longer cause a
segfault inside the _pickle C extension.
2013-07-01 15:17:45 +02:00
Christian Heimes
04926aeb2f Issue 18240: The HMAC module is no longer restricted to bytes and accepts
any bytes-like object, e.g. memoryview. Original patch by Jonas Borgström.
2013-07-01 13:08:42 +02:00
Vinay Sajip
53b1c24f54 Issue #18224: Updated test. 2013-06-30 22:11:46 +01:00
Vinay Sajip
ef1f777e0a Issue #18224: Updated test. 2013-06-30 22:11:10 +01:00
R David Murray
c170f37d38 #18038: Use non-deprecated assert names in tests. 2013-06-30 11:46:32 -04:00
R David Murray
634e076bbe Merge #18155: Regex-escape delimiter, in case it is a regex special char. 2013-06-29 18:42:24 -04:00
R David Murray
925a322570 #18155: Regex-escape delimiter, in case it is a regex special char.
Patch by Vajrasky Kok, with slight modification to the tests by me.
2013-06-29 18:40:53 -04:00
Terry Jan Reedy
06beaba785 Merge with 3.3 2013-06-29 18:22:25 -04:00
Terry Jan Reedy
e4e530e7e8 Issue #18103: Update README.txt and test_idle to describe and run gui tests. 2013-06-29 18:22:02 -04:00
Antoine Pitrou
3a5053b8cf Issue #18322: fix some test_stat nits. 2013-06-29 12:58:57 +02:00
Charles-François Natali
37cfb0a920 Issue #17914: Use os.cpu_count() instead of multiprocessing.cpu_count() where
applicable.
2013-06-28 19:25:45 +02:00
R David Murray
c723da361a Merge #14360: make encoders.encode_quopri work. 2013-06-27 18:38:36 -04:00
R David Murray
f6069f9f22 #14360: make encoders.encode_quopri work.
There were no tests for the encoders module.  encode_base64 worked
because it is the default and so got tested implicitly elsewhere, and
we use encode_7or8bit internally, so that worked, too.  I previously
fixed encode_noop, so this fix means that everythign in the encoders
module now works, hopefully correctly.  Also added an explicit test
for encode_base64.
2013-06-27 18:37:00 -04:00
Victor Stinner
5ac1b936ef test_gdb.py: ignore also "warning: Source file is more recent than executable." pattern 2013-06-25 21:54:32 +02:00
Victor Stinner
ef8115e5eb Issue #17206: Fix test_cmd_line and test_faulthandler for my previous change
(test.regrtest and test.script_helper enable faulthandler module in
subprocesses).
2013-06-25 21:54:17 +02:00
Victor Stinner
383a820e0d Issue #17206: test.regrtest and test.script_helper enable faulthandler module
in subprocesses.
2013-06-25 21:24:36 +02:00
R David Murray
4af6898dbd #11390: fix test failures due to readline and windows lineneds. 2013-06-25 08:11:22 -04:00
Raymond Hettinger
4d6018fe45 Issue 18111: Add a default argument to min() and max() 2013-06-24 22:43:02 -07:00