Gregory P. Smith
88440960f9
A stab in the dark attempt to fix the alpha/tru64 buildbot problem and add more
...
test coverage of valid inputs to zlib.crc32.
2008-03-25 06:12:45 +00:00
Neal Norwitz
40f5e4c5a2
Fix a bunch of UnboundLocalErrors when the tests fail.
2008-03-25 04:17:38 +00:00
Martin v. Löwis
aef18b1c67
Patch #2240 : Implement signal.setitimer and signal.getitimer.
2008-03-24 13:31:16 +00:00
Raymond Hettinger
bbc50eafe5
Issue 1681432: Add triangular distribution the random module.
2008-03-23 13:32:32 +00:00
Amaury Forgeot d'Arc
9a0d3462fc
#1477 : ur'\U0010FFFF' raised in narrow unicode builds.
...
Corrected the raw-unicode-escape codec to use UTF-16 surrogates in
this case, just like the unicode-escape codec.
2008-03-23 09:55:29 +00:00
Neal Norwitz
acdb6fb2a5
Try to prevent the alarm going off early in tearDown
2008-03-23 06:16:04 +00:00
Neal Norwitz
41d649116c
Suppress failure (to avoid a flaky test) if we cannot connect to svn.python.org
2008-03-23 05:47:20 +00:00
Neal Norwitz
3bda069c5a
Skip the epoll test if epoll() does not work
2008-03-23 04:43:09 +00:00
Neal Norwitz
162d719113
Speed up the test by avoiding socket timeouts.
2008-03-23 04:08:30 +00:00
Neal Norwitz
1f2995b014
Try to make this test a little more robust and not fail with:
...
timeout (10.0025) is more than 2 seconds more than expected (0.001)
I'm assuming this problem is caused by DNS lookup. This change
does a DNS lookup of the hostname before trying to connect, so the time
is not included.
2008-03-23 03:43:33 +00:00
Raymond Hettinger
e70bb8d6f2
Simplify demo code.
2008-03-23 00:55:46 +00:00
Facundo Batista
6415667fe2
Small fix that complicated the test actually when that
...
test failed.
2008-03-22 02:45:37 +00:00
Christian Heimes
0e9ab5f2f0
Applied patch #1657 epoll and kqueue wrappers for the select module
...
The patch adds wrappers for the Linux epoll syscalls and the BSD kqueue syscalls. Thanks to Thomas Herve and the Twisted people for their support and help.
TODO: Finish documentation documentation
2008-03-21 23:49:44 +00:00
Steven Bethard
d290b04ee3
Replace hack in regrtest.py with use of sys.py3kwarning.
2008-03-21 21:01:18 +00:00
Georg Brandl
65bb42dc1b
#2348 : add py3k warning for file.softspace.
2008-03-21 20:38:24 +00:00
Georg Brandl
07e5681fd3
#2346/#2347: add py3k warning for __methods__ and __members__. Patch by Jack Diederich.
2008-03-21 20:21:46 +00:00
Georg Brandl
5a44424c5e
#2358 : add py3k warning to sys.exc_clear().
2008-03-21 20:11:46 +00:00
Georg Brandl
77354cf5ef
Issue #2432 : give DictReader the dialect and line_num attributes
...
advertised in the docs.
2008-03-21 20:01:51 +00:00
Georg Brandl
331243270d
#2136 : allow single quotes in realm spec.
2008-03-21 19:54:00 +00:00
Jeffrey Yasskin
510eab5965
Speed test_threading up from 14s to .5s, and avoid a deadlock on certain
...
failures. The test for enumerate-after-join is now a little less rigorous, but
the bug it references says the error happened in the first couple iterations,
so 100 iterations should still be enough.
cProfile was useful for identifying the slow tests here.
2008-03-21 18:48:04 +00:00
Jeffrey Yasskin
413f588a36
Try to fix test_signal on FreeBSD. I'm assuming that os.kill is failing to
...
raise a signal, but switching to subprocess makes the code cleaner anyway.
2008-03-21 18:25:06 +00:00
Jeffrey Yasskin
6cda88ea11
Try to fix test_signal breakages on Linux due to r61687. It appears that at
...
least two of the linux build bots aren't leaving zombie processes around for
os.waitpid to wait for, causing ECHILD errors. This would be a symptom of a bug
somewhere, but probably not in signal itself.
2008-03-21 05:51:37 +00:00
Jeffrey Yasskin
cf26f5419e
Speed up test_signal from ~24s to 4s by avoiding nearly all of the sleep calls.
2008-03-21 05:02:44 +00:00
Eric Smith
816a168053
Comment how 'from __future__ import print_function' operates in 3.0.
2008-03-20 23:56:08 +00:00
Gregory P. Smith
6af3db8632
Attempt to fix the Solaris Sparc 10 buildbot. It was failing with an invalid
...
argument error on ioctl. This was caused by the added test_fcntl ioctl test
that hard coded 0 as the fd to use. Without a terminal, this fails on solaris.
(it passed from the command line on sol 10, both 32 and 64 bit)
Also, test_ioctl exists so I moved the test into there where it belongs.
2008-03-20 05:41:53 +00:00
Trent Nelson
00b53ea1b8
Revert r61650; the intent of this commit was to try and address alarm failures on some of the build slaves. As Neal points out, it's called after test_main(), so it's not going to factor into the test when run via regrtest.py (and removes the original functionality that Jeffrey wanted that would kill the test if it took longer than 3 seconds to run when executing it directly during development).
2008-03-20 00:58:44 +00:00
Gregory P. Smith
a5cfcad0e3
Prevent ioctl op codes from being sign extended from int to unsigned long
...
when used on platforms that actually define ioctl as taking an unsigned long.
(the BSDs and OS X / Darwin)
Adds a unittest for fcntl.ioctl that tests what happens with both positive and
negative numbers.
This was done because of issue1471 but I'm not able to reproduce -that- problem
in the first place on Linux 32bit or 64bit or OS X 10.4 & 10.5 32bit or 64 bit.
2008-03-19 23:03:25 +00:00
Brett Cannon
48581c5f08
Make sure that the warnings filter is not reset or changed beyond the current
...
running test file.
Closes issue2407. Thanks Jerry Seutter.
2008-03-19 23:01:17 +00:00
Trent Nelson
a0ce6b6b71
Bump the SIGALM delay from 3 seconds to 20 seconds, mainly in an effort to see if it fixes the alarm failures in this test experienced by some of the buildbots.
2008-03-19 22:51:42 +00:00
Raymond Hettinger
10dca6e282
The filter() function does support a None argument in Py3.0.
2008-03-19 17:58:59 +00:00
Raymond Hettinger
05387861ea
Issue 2354: Fix-up compare warning. Patch contributed by Jeff Balogh.
2008-03-19 17:45:19 +00:00
Brett Cannon
977eb021f3
Use sys.py3kwarning instead of trying to trigger a Py3k-related warning.
2008-03-19 17:37:43 +00:00
Brett Cannon
7919d98d56
test_nis would fail if test.test_support.verbose was true but NIS was not set
...
up on the machine.
Closes issue2411. Thanks Michael Bishop.
2008-03-19 16:50:13 +00:00
Eric Smith
8ff4963594
Trivial typo.
2008-03-19 12:15:10 +00:00
Eric Smith
e504445972
Use test.test_support.captured_stdout instead of a custom contextmanager.
...
Thanks Nick Coghlan.
2008-03-19 12:09:55 +00:00
Martin v. Löwis
16b2e6bd7f
Import relimport using a relative import.
2008-03-19 06:00:28 +00:00
Martin v. Löwis
a4d77898db
Issue #2400 : Allow relative imports to "import *".
2008-03-19 04:39:13 +00:00
Eric Smith
14cae96fa6
Another test for __future__ print_function.
2008-03-19 03:13:34 +00:00
David Wolever
2724ab99c8
Added zip, map, filter to future_bultins ( #2171 )
2008-03-19 02:35:45 +00:00
Eric Smith
7c47894a2a
Backport of the print function, using a __future__ import.
...
This work is substantially Anthony Baxter's, from issue
1633807. I just freshened it, made a few minor tweaks,
and added the test cases. I also created issue 2412,
which is to check for 2to3's behavior with the print
function. I also added myself to ACKS.
2008-03-18 23:45:49 +00:00
Gregory P. Smith
c856fa811d
Add a test to make sure zlib.crc32 and binascii.crc32 return the same thing.
...
Fix a buglet in binascii.crc32, the second optional argument could previously
have a signedness mismatch with the C variable its going into.
2008-03-18 22:27:41 +00:00
Steven Bethard
6a644f92ef
Add py3k warnings for code and method inequality comparisons. This should resolve issue 2373. The codeobject.c and methodobject.c changes are both just backports of the Python 3 code.
2008-03-18 22:08:20 +00:00
Steven Bethard
e8e22cf3c0
Have regrtest skip test_py3kwarn when the -3 flag is missing.
2008-03-18 21:30:13 +00:00
Neal Norwitz
0c1ef470f8
Import the test properly. This is especially important for py3k.
2008-03-18 20:30:38 +00:00
Steven Bethard
a7a3e28e4e
Fix test_atexit so that it still passes when -3 is supplied. (It was catching the warning messages on stdio from using the reload() function.)
2008-03-18 19:59:14 +00:00
Gregory P. Smith
f48da8fbcd
Fix chown on 64-bit linux. It needed to take a long (64-bit on 64bit linux) as
...
uid and gid input to accept values >=2**31 as valid while still accepting
negative numbers to pass -1 to chown for "no change".
Fixes issue1747858.
This should be backported to release25-maint.
2008-03-18 19:05:32 +00:00
Steven Bethard
8906575380
_have_soundcard() is a bad check for winsound.Beep, since you can have a soundcard but have the beep driver disabled. This revision basically disables the beep tests by wrapping them in a try/except. The Right Way To Do It is to come up with a _have_enabled_beep_driver() and use that.
2008-03-18 19:04:32 +00:00
Neal Norwitz
5fe5cf6df2
Get regrtest working when re-running tests
2008-03-18 17:58:02 +00:00
Steven Bethard
ae42f33cdf
Add py3k warnings for object, type, cell and dict comparisons. This should resolve issue2342 and partly resolve issue2373.
2008-03-18 17:26:10 +00:00
Sean Reifscheider
493894c3e0
Issue 1577: shutil.move() where destination is a directory was doing a
...
copy, now it is doing a os.rename() if it's on the same file-system.
2008-03-18 17:24:12 +00:00