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
Steven Bethard
b865f05a0f
cell_compare needs to return -2 instead of NULL.
2008-03-18 19:03:50 +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
Brett Cannon
a8b09fd4c3
Add Tools/scripts/patchcheck.py. Invoked from ``make check``, the script does
...
some verification:
- Runs reindent.py on all .py files.
- Checks if any changes in Doc exist.
- Whether Misc/ACKS was changed.
- Whether Misc/NEWS was changed.
The hope is that ``make check`` can become a command anybody can run to get
reminders about what all the requisite steps needed to create a proper
patch/checkin.
2008-03-18 17:25:13 +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
Brett Cannon
c81d3dc853
Cast the arguments to PyString_AsStringAndSize() to silence compiler warnings
...
on OS X.
2008-03-18 16:47:51 +00:00
Steven Bethard
ed427e7be9
Use test_support.unlink instead of os.unlink in tearDown(). (Seems to fix an occasional failure in Windows Vista.)
2008-03-18 16:00:19 +00:00
Brett Cannon
f084e04820
Fix test_errno to only check for error numbers that are defined by Standard C.
2008-03-18 15:52:00 +00:00
Brett Cannon
10ed0f50a9
Remove all traces of HAVE_STRERROR.
...
The removal of strerror.c led to the function check being removed from
configure.in.
2008-03-18 15:35:58 +00:00
Thomas Heller
50a24d8bfd
Include <alloca.h> on Solaris, see issue #1506 .
...
It would probably be better to have a configure test for that, but
this is outside of my configure expertise.
2008-03-18 15:03:17 +00:00
Martin v. Löwis
66e2663eba
Note that the stderr output of the test is intentional.
2008-03-18 13:16:05 +00:00
Martin v. Löwis
afb416b002
Add WSA errors.
2008-03-18 13:05:03 +00:00
Martin v. Löwis
637f239bbb
Add more Linux error codes.
2008-03-18 12:45:37 +00:00
Martin v. Löwis
d43ca3b395
norwitz-amd64 (gentoo) has EREMOTEIO.
2008-03-18 12:20:15 +00:00
Trent Nelson
496ad27186
The behaviour of winsound.Beep() seems to differ between different versions of Windows when there's either:
...
a) no sound card entirely
b) legacy beep driver has been disabled
c) the legacy beep driver has been uninstalled
Sometimes RuntimeErrors are raised, sometimes they're not. If _have_soundcard() returns False, don't expect winsound.Beep() to raise a RuntimeError, as this clearly isn't the case, as demonstrated by the various Win32 XP buildbots.
2008-03-18 07:32:47 +00:00
Trent Nelson
3ce76756d3
Issue 2286: bump up the stack size of the 64-bit debug python_d.exe to 2100000. The default value of 200000 causes a stack overflow at 1965 iterations of r_object() in marshal.c, 35 iterations before the 2000 limit enforced by MAX_MARSHAL_STACK_DEPTH.
2008-03-18 07:02:12 +00:00
Neal Norwitz
d1befd7c50
Add some info to the failure messages
2008-03-18 06:03:46 +00:00
Jeffrey Yasskin
36dbcb9e98
Add a -S/--slow flag to regrtest to have it print the 10 slowest tests with
...
their times.
2008-03-18 05:45:40 +00:00
Brett Cannon
08811dde5d
Improve the error message for a test that failed on the S-390 Debian buildbot.
2008-03-18 05:43:04 +00:00
Neal Norwitz
819f139c4b
Try increasing the timeout to reduce the flakiness of this test.
2008-03-18 05:20:29 +00:00
Jeffrey Yasskin
ed414654c4
Speed up test_dict by about 10x by only checking selected dict literal sizes,
...
instead of every integer from 0 to 400. Exhaustive testing wastes time without
providing enough more assurance that the code is correct.
2008-03-18 05:12:41 +00:00
Jeffrey Yasskin
a14585308a
Speed test_thread up from 51.328s to 0.081s by reducing its sleep times. We
...
still sleep at all to make it likely that all threads are active at the same
time.
2008-03-18 04:56:06 +00:00
Neal Norwitz
b1d3d96374
Issue 2332: add new attribute names for instance method objects
2008-03-18 04:46:00 +00:00
Travis E. Oliphant
3781aef8f8
Finish backporting new buffer API to Python 2.6. Left to do: memoryview object and structmodule. But, these need to be finished in Python 3.0 first. No objects support the new buffer API in Python 2.6 as of yet, and except for the memoryview object, I don't think they will.
2008-03-18 04:44:57 +00:00
Guido van Rossum
6d91be3758
- Issue 2379: Raise a Py3K warning for __getitem__ or __getslice__ on
...
exception instances.
2008-03-18 04:42:22 +00:00
Jeffrey Yasskin
0bfc896979
Block the "socket.ssl() is deprecated" warning from test_socket_ssl.
2008-03-18 04:29:35 +00:00
Guido van Rossum
504153d55b
Issue #2341 : Add a Py3k warning when raising an exception that doesn't
...
derive from BaseException.
2008-03-18 04:26:48 +00:00
Brett Cannon
a5573b3153
The output directory for tests that compare against stdout is now gone!
2008-03-18 04:16:06 +00:00
Brett Cannon
aa5778d1b8
Remove our implementation of memmove() and strerror(); both are in the C89
...
standard library.
2008-03-18 04:09:00 +00:00
Brett Cannon
b7ec8e5a9e
test_errno was a no-op test; now it actually tests things and uses unittest.
2008-03-18 03:46:22 +00:00
Guido van Rossum
20bda581e3
Clean up the Py3k warnings for non-BaseException-subclasses a bit. We
...
now don't warn for some corner cases that deserve a warning, rather
than warning double or incorrectly for some other corner cases.
2008-03-18 03:15:05 +00:00
Guido van Rossum
04edb528ca
- Issue #2371 : Add a Py3k warning when catching an exception that
...
doesn't derive from BaseException.
2008-03-18 02:49:46 +00:00
Brett Cannon
0bb7950829
Move test_extcall to doctest.
2008-03-18 01:58:56 +00:00
Brett Cannon
ba17cfc66c
Convert test_dummy_threading and test_dbm to unittest.
2008-03-18 01:50:25 +00:00
Jeffrey Yasskin
5de250e823
Fix build on platforms that don't have intptr_t. Patch by Joseph Armbruster.
2008-03-18 01:09:59 +00:00
Brett Cannon
6eeaddc341
Convert test_strftime, test_getargs, and test_pep247 to use unittest.
2008-03-18 01:00:07 +00:00
Gregory P. Smith
887290d275
Fix the IOError message text when opening a file with an invalid filename.
...
Error reported by Ilan Schnell.
2008-03-18 00:20:01 +00:00
Martin v. Löwis
a7d57cd433
Add David Wolever.
2008-03-17 21:55:30 +00:00
Neal Norwitz
419fd49abe
Issue 2321: reduce memory usage (increase the memory that is returned
...
to the system) by using pymalloc for the data of unicode objects.
Will backport.
2008-03-17 20:22:43 +00:00
Eric Smith
0aed07ad80
Added PEP 3127 support to tokenize (with tests); added PEP 3127 to NEWS.
2008-03-17 19:43:40 +00:00
Steven Bethard
6f778cfb5b
Document unicode.isnumeric() and unicode.isdecimal() (issue2326)
2008-03-17 19:33:11 +00:00
Neal Norwitz
f13572d6e4
Use a buffer large enough to ensure we don't overrun, even if the value
...
is outside the range we expect.
2008-03-17 19:02:45 +00:00
Gregory P. Smith
f48f9d38c0
Force zlib.crc32 and zlib.adler32 to return a signed integer on all platforms
...
regardless of the native sizeof(long) used in the integer object.
This somewhat odd behavior of returning a signed is maintained in 2.x for
compatibility reasons of always returning an integer rather than a long object.
Fixes Issue1202 for Python 2.6
2008-03-17 18:48:05 +00:00
Travis E. Oliphant
33451d8ab1
Add necessary headers to back-port new buffer protocol to Python 2.6
2008-03-17 17:36:12 +00:00
Eric Smith
9ff19b5434
Finished backporting PEP 3127, Integer Literal Support and Syntax.
...
Added 0b and 0o literals to tokenizer.
Modified PyOS_strtoul to support 0b and 0o inputs.
Modified PyLong_FromString to support guessing 0b and 0o inputs.
Renamed test_hexoct.py to test_int_literal.py and added binary tests.
Added upper and lower case 0b, 0O, and 0X tests to test_int_literal.py
2008-03-17 17:32:20 +00:00
Martin v. Löwis
7cfbf0c421
Add Trent Nelson.
2008-03-17 16:31:57 +00:00
Jeffrey Yasskin
b9e15f7555
Make isinstance(OldstyleClass, NewstyleClass) return False instead of raising
...
an exception. Issue reported by Joseph Armbruster.
2008-03-17 16:31:21 +00:00
Jeffrey Yasskin
1b4e45bab9
Allow Gnu gcc's to build python on OSX by removing -Wno-long-double,
...
-no-cpp-precomp, and -mno-fused-madd from configure.
* r22183 added -no-cpp-precomp, which
http://gcc.gnu.org/ml/gcc/2005-12/msg00368.html claims hasn't been
needed since gcc-3.1.
* r25607 added -Wno-long-double to avoid a warning in
Include/objimpl.h (issue 525481). The long double is still there,
but OSX 10.4's gcc no longer warns about it.
* r33666 fixed issue 775892 on OSX 10.3 by adding -mno-fused-madd,
which changed the sign of some float 0s. Tim Peters said it wasn't
a real issue anyway, and it no longer causes test failures.
Fixes issue #1779871 .
2008-03-17 14:40:53 +00:00
Eric Smith
5c35a9da65
Reformated lines > 79 chars.
...
Deleted unused macro ISXDIGIT.
2008-03-17 12:14:29 +00:00