Commit Graph

15779 Commits

Author SHA1 Message Date
Michael Foord 931190b4f5 Support dotted module names for test discovery paths in unittest. Issue 7780. 2010-04-03 01:15:21 +00:00
Benjamin Peterson 2b79fdfc69 split out large test function 2010-04-03 01:08:34 +00:00
Brian Curtin e9da81c62b Fix assertRaises usage on reflection functions which should raise
NotImplementedError on Windows XP and below.
2010-04-03 00:59:32 +00:00
Raymond Hettinger 3928276e64 Clear cyclical references in list based OrderedDict. 2010-04-03 00:39:26 +00:00
Benjamin Peterson 4564c08b26 set svn:eol-style on new file 2010-04-02 23:31:40 +00:00
Brian Curtin e5aa886b44 Implement #1220212. Add os.kill support for Windows.
os.kill takes one of two newly added signals, CTRL_C_EVENT and
CTRL_BREAK_EVENT, or any integer value. The events are a special case
which work with subprocess console applications which implement a
special console control handler. Any other value but those two will
cause os.kill to use TerminateProcess, outright killing the process.

This change adds win_console_handler.py, which is a script to implement
SetConsoleCtrlHandler and applicable handler function, using ctypes.

subprocess also gets another attribute which is a necessary flag to
creationflags in Popen in order to send the CTRL events.
2010-04-02 23:26:06 +00:00
Michael Foord a04c7a0f16 Issue #8038: Addition of unittest.TestCase.assertNotRegexpMatches 2010-04-02 22:55:59 +00:00
Michael Foord 25d7976014 unittest tests no longer replace the sys.stdout put in place by regrtest 2010-04-02 22:30:56 +00:00
Mark Dickinson 7c63eee485 Issue #8294: Allow float and Decimal arguments in Fraction constructor. 2010-04-02 22:27:36 +00:00
Michael Foord 58c1e78806 TestResult stores original sys.stdout and tests no longer use sys.__stdout__ (etc) in tests for unittest -b command line option 2010-04-02 22:08:29 +00:00
Ezio Melotti 7999deafc8 Fix test_compiler.py that was using unittest.__file__ to find Lib/ (unittest is now a package). 2010-04-02 21:43:10 +00:00
Michael Foord 5637f04a94 Addition of -b command line option to unittest for buffering stdout and stderr during test runs. 2010-04-02 21:42:47 +00:00
Brian Curtin e33fa887d3 Implement #7347. Add CreateKeyEx, DeleteKeyEx, and update _winreg tests.
*ReflectionKey functions used to not be documented or tested, but they are
now sufficiently documented and tested on platforms where they apply.
Additionally, fixed a bug in QueryReflectionKey which was returning an
incorrect value.

All tests pass from XP through Windows 7, on 32 and 64-bit platforms.
2010-04-02 21:18:14 +00:00
Tarek Ziadé ef253ac84e removed the local copy of xxmodule, and skip only test_build_ext when xxmodule is not found, not the whole unittest 2010-04-02 21:14:04 +00:00
Raymond Hettinger ed171abd93 Issue 8257: Decimal constructor to accept float. 2010-04-02 18:39:24 +00:00
Florent Xicluna f37592fda1 Backport some robotparser test and skip the test if the external resource is not available. 2010-04-02 17:26:42 +00:00
Andrew M. Kuchling d54e699cba #4440: modernize a use of filter(), making it compatible with 3.x 2010-04-02 16:59:16 +00:00
Eric Smith d44b2fc87c Issue 7994: Make object.__format__ with a non-empty format string a PendingDecprecationWarning. Still need to remove uses of this from various tests. 2010-04-02 12:30:56 +00:00
Mark Dickinson f3eeca16cb Issue #7279: Make Decimal('nan') hashable. Decimal('snan') remains unhashable.
Also rewrite the Decimal __hash__ method so that it doesn't rely on
float('inf') being valid: float('inf') could raise an exception on
platforms not using IEEE 754 arithmetic.
2010-04-02 10:35:12 +00:00
Mark Dickinson e096e82e82 Issue #7279: Make comparisons involving a Decimal sNaN signal InvalidOperation. 2010-04-02 10:17:07 +00:00
Mark Dickinson 99d8096c17 Issue #2531: Make float-to-decimal comparisons return correct results.
Float to decimal comparison operations now return a result based on
the numeric values of the operands.  Decimal.__hash__ has also been
fixed so that Decimal and float values that compare equal have equal
hash value.
2010-04-02 08:53:22 +00:00
Florent Xicluna dfd3618422 #7092: silence some py3k warnings 2010-04-02 08:30:21 +00:00
Florent Xicluna a7f242fa2a #7092: Drop the cmp argument. 2010-04-02 08:15:26 +00:00
Florent Xicluna d630c04ab1 #7092: Fix additional "-3" warnings in the idlelib package, and convert to absolute imports. 2010-04-02 07:24:52 +00:00
Florent Xicluna 8d1da0f5c3 #7092: Fix some -3 warnings, and fix Lib/platform.py when the path contains a double-quote. 2010-04-01 18:17:09 +00:00
Antoine Pitrou b5023df3d6 Issue #8281: rename test_gdb_sample.py to gdb_sample.py, otherwise it gets picked
as a regular test by regrtest.py, and fails.
2010-04-01 17:56:57 +00:00
Martin v. Löwis bf0dfb3d0e Issue #8032: For gdb7, a python-gdb.py file is added to the build,
allowing to use advanced gdb features when debugging Python.
2010-04-01 07:40:51 +00:00
Brian Curtin a01da93d85 Fix a test_pydoc failure on Neal Norwitz's buildbot. 2010-04-01 04:02:00 +00:00
Florent Xicluna 6257a7bbb2 Replace catch_warnings with check_warnings when it makes sense. Use assertRaises context manager to simplify some tests. 2010-03-31 22:01:03 +00:00
Antoine Pitrou a57df2cf1d Issue #8268: Old-style classes (not just instances) now support weak
references.
2010-03-31 21:32:15 +00:00
Florent Xicluna 26cc99da2a Fix test for xml.etree when using a non-ascii path. And use check_warnings instead of catch_warnings. 2010-03-31 21:21:54 +00:00
Barry Warsaw f7f2d6f51e - Issue #8233: When run as a script, py_compile.py optionally takes a single
argument `-` which tells it to read files to compile from stdin.  Each line
  is read on demand and the named file is compiled immediately.  (Original
  patch by Piotr Ożarowski).
2010-03-31 21:07:16 +00:00
Brian Curtin fe4900c0bc Correct what was intended to be a single-tuple to just be a != check.
Thanks to Éric Araujo for noticing that.
2010-03-31 17:36:09 +00:00
Ezio Melotti fcc500ebc4 Silence a py3k warning. 2010-03-31 08:33:50 +00:00
Brian Curtin aeb2e8295d Fix #8225. xml.etree was displaying an incorrect link when viewed in help. 2010-03-31 03:10:21 +00:00
Thomas Heller b102ddadcb Revert rev. 79509; ctypes doesn't build on linux. 2010-03-30 20:57:06 +00:00
Thomas Heller 5006ba0fef Merged revisions 79115,79424,79491 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/branch_libffi-3_0_10-win

........
  r79115 | thomas.heller | 2010-03-19 22:14:47 +0100 (Fr, 19 Mrz 2010) | 7 lines

  Work in progress.  2 tests fail on x86/win32 because the stack
  checking code in ffi_call_win32 is not yet implemented.

  Remove most files from _ctypes/libffi_msvc, only two include files
  stay (updated from _ctypes/libffi/...).  Other files are used in the
  cross-platform _ctypes/libffi directory.
........
  r79424 | thomas.heller | 2010-03-25 19:28:02 +0100 (Do, 25 Mrz 2010) | 1 line

  Build _ctypes on Win64.
........
  r79491 | thomas.heller | 2010-03-29 21:30:33 +0200 (Mo, 29 Mrz 2010) | 4 lines

  On Windows, ctypes does no longer check the stack before and after
  calling a foreign function.
  This allows to use the unmodified libffi library.
........
2010-03-30 19:46:23 +00:00
Antoine Pitrou 8f66efe253 Fix small error in r79502 2010-03-30 18:58:22 +00:00
Antoine Pitrou 6032c25063 Issue #8248: Add some tests for the bool type. Patch by Gregory Nofi. 2010-03-30 18:49:45 +00:00
Benjamin Peterson 7e213255ce add inspect.getcallargs, which binds function arguments like a normal call #3135
Patch by George Sakkis
2010-03-30 17:58:13 +00:00
Florent Xicluna 75c6676916 #8263: Now regrtest.py will report a failure if it receives a KeyboardInterrupt (SIGINT). 2010-03-30 16:31:14 +00:00
Florent Xicluna 22b243809e #7643: Unicode codepoints VT (0x0B) and FF (0x0C) are linebreaks according to Unicode Standard Annex #14. 2010-03-30 08:24:06 +00:00
Michael Foord e6410c536c Backport of weakref.WeakSet and tests from Python 3. 2010-03-29 20:04:23 +00:00
Michael Foord a7e08fe3f8 Addition of delta keyword argument to unittest.TestCase.assertAlmostEquals and assertNotAlmostEquals
This allows the comparison of objects by specifying a maximum difference; this includes the comparing of non-numeric objects that don't support rounding.
2010-03-27 19:10:11 +00:00
Michael Foord b35ecf4775 Rename the unittest test_suite function to not clash with a test module name (unittest.test.test_suite is now unambiguous). 2010-03-27 13:42:34 +00:00
Michael Foord ff889396a8 A fix for running unittest tests on platforms without the audioop module (e.g. jython and IronPython) 2010-03-27 12:55:19 +00:00
Mark Dickinson 71b7fac07b Make Fraction to complex comparisons with <=, <, >= or > raise TypeError. 2010-03-27 11:09:29 +00:00
Florent Xicluna 355adc5a45 Ensure that the failed or unexpected tests are sorted before printing. 2010-03-26 19:32:44 +00:00
Benjamin Peterson c7024e7fd6 reorder imports 2010-03-26 13:53:32 +00:00
Michael Foord fa2f1cdcbb Addition of -c command line option to unittest, to handle ctrl-c during a test run more elegantly 2010-03-26 03:18:31 +00:00
Michael Foord ee627883a7 Move a support TestCase out of the main namespace in unittest.test.test_suite 2010-03-26 02:53:56 +00:00
Michael Foord 95ac82bfc6 Remove incorrect docstring in unittest.test 2010-03-26 00:03:38 +00:00
Michael Foord 35b3792ed3 Turn unittest tests into a package 2010-03-25 23:56:33 +00:00
Florent Xicluna fd37dd46e8 Fix test_unittest and test_warnings when running "python -Werror -m test.regrtest" 2010-03-25 20:39:10 +00:00
Florent Xicluna 8aa5a581d3 #8207: Fix test_pep277 on OS X 2010-03-25 20:33:49 +00:00
Florent Xicluna c8a730bf72 Syntax cleanup `== None` -> `is None` 2010-03-25 20:32:07 +00:00
Larry Hastings 402b73fb8d Backported PyCapsule from 3.1, and converted most uses of
CObject to PyCapsule.
2010-03-25 00:54:54 +00:00
Steven Bethard 2ec1f27716 Replace license with simple attribution. 2010-03-24 23:03:24 +00:00
Antoine Pitrou 2c6799ab8c Revert r79384 (the fix failed). 2010-03-24 22:12:15 +00:00
Benjamin Peterson fb224e3034 replace copy right notice with simple attribution 2010-03-24 22:03:09 +00:00
Antoine Pitrou 914bdbb495 Trying to fix #8108. Will watch the buildbot(s). 2010-03-24 21:55:12 +00:00
Florent Xicluna 36b9fbb803 Skip tests which depend on multiprocessing.sharedctypes, if _ctypes is not available. 2010-03-24 19:33:25 +00:00
Florent Xicluna 27e024023c Skip test_ascii_formatd if _ctypes is not available (BSD, ...).
Previous change was incomplete (r79334).
2010-03-24 17:32:58 +00:00
Vinay Sajip b0623d64a8 logging: Added LOG_FTP for SysLogHandler and updated documentation. 2010-03-24 14:31:21 +00:00
Florent Xicluna 3c919cf140 The SIGINT signal may happen earlier, during site.py initialization. 2010-03-23 19:19:16 +00:00
Florent Xicluna 446ff14827 The standard error should be empty when the signal is killed, except on SIGINT. 2010-03-23 15:05:30 +00:00
Florent Xicluna fc4d6d7763 Silence test_subprocess. 2010-03-23 14:36:45 +00:00
Florent Xicluna 875bdf731c Skip test_format_deprecation if _ctypes is not available. Add a filter to the warning check. 2010-03-23 11:07:54 +00:00
Benjamin Peterson 996e88a7d5 Merged revisions 79313,79324 via svnmerge from
svn+ssh://pythondev@svn.python.org/sandbox/trunk/2to3/lib2to3

........
  r79313 | benjamin.peterson | 2010-03-22 17:59:57 -0500 (Mon, 22 Mar 2010) | 1 line

  another case where a symbol is needed
........
  r79324 | benjamin.peterson | 2010-03-22 21:59:47 -0500 (Mon, 22 Mar 2010) | 1 line

  use unicode literals
........
2010-03-23 03:03:55 +00:00
Benjamin Peterson 3bcc35b795 Merged revisions 79309 via svnmerge from
svn+ssh://pythondev@svn.python.org/sandbox/trunk/2to3/lib2to3

........
  r79309 | benjamin.peterson | 2010-03-22 17:50:47 -0500 (Mon, 22 Mar 2010) | 1 line

  pass correct symbol in
........
2010-03-22 22:54:42 +00:00
Florent Xicluna 176cda11df Issue #8205: Remove the "Modules" directory from sys.path when Python is running from the build directory (POSIX only). 2010-03-22 22:52:11 +00:00
Florent Xicluna e1f4c92d23 #7667: Fix doctest failures with non-ASCII paths. 2010-03-22 22:45:50 +00:00
Benjamin Peterson 798e54004f Merged revisions 79077,79137,79304-79305 via svnmerge from
svn+ssh://pythondev@svn.python.org/sandbox/trunk/2to3/lib2to3

........
  r79077 | benjamin.peterson | 2010-03-18 18:05:29 -0500 (Thu, 18 Mar 2010) | 1 line

  port detect_encoding improvements from py3k
........
  r79137 | benjamin.peterson | 2010-03-20 11:12:53 -0500 (Sat, 20 Mar 2010) | 1 line

  add a fixer for setting sys.exitfunc #2356
........
  r79304 | benjamin.peterson | 2010-03-22 17:20:22 -0500 (Mon, 22 Mar 2010) | 1 line

  fix test_parser when it's run in a path with spaces #7666
........
  r79305 | benjamin.peterson | 2010-03-22 17:27:07 -0500 (Mon, 22 Mar 2010) | 1 line

  normalize whitespace
........
2010-03-22 22:40:06 +00:00
Antoine Pitrou 513d9aeadb Issue #7512: shutil.copystat() could raise an OSError when the filesystem
didn't support chflags() (for example ZFS under FreeBSD).  The error is
now silenced.
2010-03-22 19:59:46 +00:00
Florent Xicluna 0805e6eed9 #7668: Fix test_httpservers failure when sys.executable contains non-ASCII bytes. 2010-03-22 17:18:18 +00:00
Florent Xicluna 9e7a4c9738 Issue #7703: ctypes supports both buffer() and memoryview(). The former is deprecated.
Complement of r79288.
2010-03-22 16:07:38 +00:00
R. David Murray c9d1a7845b Issue #7860: platform.uname now reports the correct 'machine' type
when Python is running in WOW64 mode on 64 bit Windows.  Patch by
Brian Curtin.
2010-03-22 15:55:09 +00:00
Vinay Sajip 804899b4ab logging: Added getChild utility method to Logger and added isEnabledFor method to LoggerAdapter. 2010-03-22 15:29:01 +00:00
Jesus Cea 73c22e9df2 Missing testsuite files 2010-03-22 15:18:46 +00:00
Florent Xicluna f08a0176a7 Get rid of buffer() in test_ctypes: backport the 3.x tests. 2010-03-22 15:02:46 +00:00
Antoine Pitrou 52093b8e57 Fix an occasional test_ftplib failure, following r79226. 2010-03-22 14:41:48 +00:00
Jesus Cea 6557aac599 pybsddb 4.8.4 integration. Please, comment in issue #8156 2010-03-22 14:22:26 +00:00
Vinay Sajip 31e928eb3c Issue #8201: logging: Handle config errors when non-ASCII and Unicode logger names exist at the same time. 2010-03-22 13:02:28 +00:00
Victor Stinner c7790ed163 Fix the NEWS about my last commit: an unicode subclass can now override the
__unicode__ method (and not the __str__ method).

Simplify also the testcase.
2010-03-22 12:36:28 +00:00
Vinay Sajip 3017a7bbbf Issue #8200: logging: Handle errors when multiprocessing is not fully loaded when logging occurs. 2010-03-22 12:33:08 +00:00
Victor Stinner 95affc4449 Issue #1583863: An unicode subclass can now override the __str__ method 2010-03-22 12:24:37 +00:00
Michael Foord eef159bd17 Correct usage message displayed for python -m unittest -h 2010-03-22 02:49:08 +00:00
Michael Foord 0ce167277a expected failure should not trigger failfast behavior in unittest. 2010-03-22 01:56:54 +00:00
Michael Foord 49899690a8 Removing Python 2.3 compatibility code from unittest. 2010-03-22 01:41:11 +00:00
Michael Foord db003cb3d1 Fix failing test committed by accident. 2010-03-22 01:02:23 +00:00
Michael Foord 1b9e95339d -f/--failfast command line option for unittest. Issue 8074. Documentation still needed. Plus minor change to test_unittest to allow it to be run with python -m test.unittest 2010-03-22 01:01:34 +00:00
Michael Foord b1aa30f94d Issue 7815. __unittest in module globals trims frames from reported stacktraces in unittest. 2010-03-22 00:06:30 +00:00
Benjamin Peterson bb9d726357 take into account keyword arguments when passing too many args 2010-03-21 20:30:30 +00:00
Benjamin Peterson 965458931f improve error message from passing inadequate number of keyword arguments #6474
Note this removes the "non-keyword" or "keyword" phrases from these messages.
2010-03-21 20:21:00 +00:00
Benjamin Peterson 54bc22e9f3 don't write duplicate tests 2010-03-21 19:56:37 +00:00
Benjamin Peterson 52b32b6d6a fix import 2010-03-21 19:54:56 +00:00
Antoine Pitrou 448da71807 Issue #3890: Fix recv() and recv_into() on non-blocking SSL sockets. 2010-03-21 19:33:38 +00:00
Florent Xicluna 77a8849505 #8180: Fix test_pep277 on OS X and add more tests for special Unicode normalization cases. 2010-03-21 18:00:38 +00:00
Benjamin Peterson e39b2ec6ca rewrite a bit 2010-03-21 17:34:54 +00:00
Florent Xicluna cf82fa6f91 Issue #8179: Fix macpath.realpath() on a non-existing path. 2010-03-21 12:27:20 +00:00
Florent Xicluna b88fbf4fef Use assertRaises and add a specific warning filter. 2010-03-21 11:58:11 +00:00
Florent Xicluna 3f5d146323 No more deprecation warnings for distutils.sysconfig, following r78666.
But when the "dl" module is available, it gives a py3k deprecation warning.
2010-03-21 11:50:17 +00:00
Florent Xicluna af61719ec3 Silence some py3k SyntaxWarning using check_py3k_warnings() with "exec" statements. 2010-03-21 11:03:21 +00:00
Florent Xicluna 8f43cec41b Fix py3k warnings in test_decimal, using unittest.assertItemsEqual. 2010-03-21 10:51:40 +00:00
Florent Xicluna 4a0f8b89f6 Silence more py3k warnings in unittest.case. 2010-03-21 10:50:44 +00:00
Florent Xicluna 0762788081 #7092 - Silence more py3k deprecation warnings, using test_support.check_py3k_warnings() helper. 2010-03-21 01:14:24 +00:00
Michael Foord 8cb253f8d6 Change order of arguments in a unittest function. 2010-03-21 00:55:58 +00:00
Michael Foord 73dbe04619 A faulty load_tests in a test module no longer halts test discovery. A placeholder test, that reports the failure, is created instead. 2010-03-21 00:53:39 +00:00
Florent Xicluna fc5f6a7f40 Cleanup test_tarfile, and use check_warnings. 2010-03-20 22:26:42 +00:00
Florent Xicluna db4a321fea Cleanup test_struct using check_warnings. 2010-03-20 22:21:02 +00:00
Michael Foord 98e7b7644b Issue 7832: renaming unittest.TestCase.assertSameElements to assertItemsEqual and changing behaviour 2010-03-20 03:00:34 +00:00
Florent Xicluna 2e6d2622bd #8178 Cleanup the threads after test_thread.TestForkInThread. 2010-03-20 00:17:46 +00:00
Florent Xicluna bc27c6a5aa Various tests cleanup: check_warnings/check_py3k_warnings, unittest.assert* and setUp/tearDown. 2010-03-19 18:34:55 +00:00
Matthias Klose e9fbf2b943 - Issue #1039, #8154: Fix os.execlp() crash with missing 2nd argument. 2010-03-19 14:45:06 +00:00
Benjamin Peterson f4fd0bf7c1 keep DeprecationWarning from failing test 2010-03-19 01:06:33 +00:00
Benjamin Peterson 52d4aeac86 make compiler's py3k warning a full deprecation warning #6837 2010-03-18 23:12:43 +00:00
Benjamin Peterson e30b3fa17a these lines can now be dispensed with 2010-03-18 22:44:54 +00:00
Collin Winter 001a3952c9 Add support for weak references to code objects. This will be used by an optimization in the incoming Python 3 JIT.
Patch by Reid Kleckner!
2010-03-18 21:54:01 +00:00
Florent Xicluna 2e0a53fdf6 Issue #8024: Update the Unicode database to 5.2 2010-03-18 21:50:06 +00:00
Florent Xicluna 735885428d #8155: Preserve backward compatibility for test_support.check_warnings(). Add regression tests. 2010-03-18 19:51:47 +00:00
Senthil Kumaran f3e9b2a996 Fix for Issue8135 - urllib.unquote to support mixed percent escapes 2010-03-18 12:14:15 +00:00
Collin Winter 43fe03a206 Make test_pwd more stable in the face of unusual LDAP/NIS/Kerberos deployments (the old test was flaky on Google buildslaves). 2010-03-18 00:10:34 +00:00
Antoine Pitrou d7b731d160 Issue #8104: socket.recv_into() and socket.recvfrom_into() now support
writing into objects supporting the new buffer API, for example bytearrays
or memoryviews.
2010-03-17 22:45:39 +00:00
Collin Winter 2227251a4e Fix a race condition in test_asynchat uncovered by the Unladen Swallow JIT. 2010-03-17 22:36:26 +00:00
Benjamin Peterson 0dee9c1b5c prevent lambda functions from having docstrings #8164 2010-03-17 20:41:42 +00:00
Florent Xicluna 78c1871d21 Fix and check cgi module deprecation warnings. Revert an unwanted rename in test_import. 2010-03-17 20:05:11 +00:00
Florent Xicluna 945a8ba635 Cleanup some test cases using check_warnings and check_py3k_warnings. 2010-03-17 19:15:56 +00:00
Florent Xicluna 2b73c21bed Cleanup in test_import and test_coding. 2010-03-17 19:05:04 +00:00
Collin Winter 786431282b Avoid hardcoding refcounts in tests. 2010-03-17 17:36:16 +00:00
Vinay Sajip 2060e42206 Issue #8162: logging: Clarified docstring and documentation for disable function. 2010-03-17 15:05:57 +00:00
Ezio Melotti 187f93d986 Use "x in y" instead of y.find(x) != -1. 2010-03-17 14:22:34 +00:00
Ezio Melotti d80b4bfd0b #7092: silence some more py3k warnings. 2010-03-17 13:52:48 +00:00
Collin Winter 8b3f1ce591 Delete unused import. 2010-03-17 03:04:01 +00:00
Collin Winter 89b4f13024 Style cleanup in test_import. 2010-03-17 02:40:12 +00:00
Collin Winter ac1d93167c Fix a trivial class of (hypothetical, future) false-positive refleaks, discovered by an optimization in Unladen Swallow's past (which will become CPython's future). 2010-03-17 02:02:30 +00:00
Matthias Klose 8b41168bab - Issue #4961: Inconsistent/wrong result of askyesno function in tkMessageBox
with Tcl/Tk-8.5.
2010-03-16 10:48:52 +00:00
Florent Xicluna 3cc8f211ed Issue #7783 and #7787: open_urlresource invalidates the outdated files from the local cache.
Use this feature to fix test_normalization.
2010-03-15 18:08:58 +00:00
Matthias Klose fae23dc9dc - Fix typo in Lib/compileall.py(__all__). 2010-03-15 18:00:01 +00:00
Matthias Klose b13d04c991 - Issue #8140: extend compileall to compile single files. Add -i option. 2010-03-15 17:44:12 +00:00
Matthias Klose 358e7ff36b - Issue #7356: ctypes.util: Make parsing of ldconfig output independent of
the locale.
2010-03-15 13:42:23 +00:00
Matthias Klose 54cc539a2b - Issue #6949: Allow the _bsddb extension to be built with db-4.8.x. 2010-03-15 12:46:18 +00:00
Benjamin Peterson f56813997f clean up files correctly 2010-03-15 03:02:37 +00:00
Benjamin Peterson 5a4c0f5cc2 remove mac 9 code 2010-03-15 03:00:35 +00:00
Benjamin Peterson ca02f3a4d6 this little exception dance is pointless 2010-03-15 02:58:24 +00:00
Florent Xicluna ece29b2aac Do not hardcode Expat version. It's possible to build Python with --with-system-expat option. 2010-03-14 15:20:59 +00:00
Florent Xicluna 88db6f402e Minor documentation updates for xml.etree. 2010-03-14 01:22:09 +00:00
Florent Xicluna 1b51c3d4de Do not chdir when running test_xml_etree, and enhance the findfile helper. 2010-03-13 12:41:48 +00:00
Florent Xicluna 13ba1a1c65 Move the xml test data to their own directory. 2010-03-13 11:18:49 +00:00
Victor Stinner 6e055d78e1 sqlite3: Fix a segfault on calling a connection with something else than a
string. Initialize all attributes to be able to call the statement destructor
on error.

Avoid also a duplicate connection in some tests: setUp() does already open a
connection (":memory:").
2010-03-13 03:27:07 +00:00
Victor Stinner 17d905449d Issue #7818: set().test_c_api() doesn't expect a set('abc'), modify the set. 2010-03-13 00:13:22 +00:00
Vinay Sajip 9098ee4360 Issue #8117: logging: Improved algorithm for computing initial rollover time. 2010-03-12 06:01:21 +00:00
Benjamin Peterson 654ea3713e remove shebang line from non-executable test 2010-03-11 22:34:12 +00:00
Benjamin Peterson 9cf41d0c9d normalize shebang lines to #!/usr/bin/env python 2010-03-11 22:33:25 +00:00
Benjamin Peterson afa595b31b revert r78842 cgi.py change 2010-03-11 22:03:45 +00:00
Benjamin Peterson 651bc32a4e use proper shebang lines 2010-03-11 21:53:25 +00:00
Benjamin Peterson 75c8be048b remove executable property from doc files 2010-03-11 21:50:45 +00:00
Florent Xicluna e2e81e8fcd Fix repr of tree Element on windows. 2010-03-11 15:55:11 +00:00
Florent Xicluna 3e8c189faa Issue #6472: The xml.etree package is updated to ElementTree 1.3. The cElementTree module is updated too. 2010-03-11 14:36:19 +00:00
Victor Stinner 4478662f83 Another fix to test_executable() of test_sys: set the current working to avoid
the #7774 bug.
2010-03-11 13:46:06 +00:00
Victor Stinner 6ecd85f401 Fix test_executable introduce in previous commit (r78835): Windows is able to
retrieve the absolute Python path even if argv[0] has been set to a non
existent program name.
2010-03-11 13:27:35 +00:00
Victor Stinner 4a7e0c858c Issue #7774: Set sys.executable to an empty string if argv[0] has been
set to an non existent program name and Python is unable to retrieve the real
program name.

Fix also sysconfig: if sys.executable is an empty string, use the current
working directory.
2010-03-11 12:34:39 +00:00
Florent Xicluna 637637021a Revert r78830: realpath() should really be applied to sys.executable. 2010-03-11 01:50:48 +00:00
Florent Xicluna 6602ec6eff It is not optimal to test sys.stderr on a debug build. 2010-03-11 01:39:55 +00:00
Florent Xicluna e58d91c8f0 Fix the test_subprocess failure when sys.executable is meaningless: '' or a directory.
It does not fix #7774.
2010-03-11 00:56:59 +00:00
Florent Xicluna 85677617d5 Issue #7880: Fix sysconfig when the python executable is a symbolic link. 2010-03-10 23:58:42 +00:00
Victor Stinner 3ec32005e8 ooops, fix error message in execusercustomize()
Copy/paste failure :-)
2010-03-10 22:45:04 +00:00
Victor Stinner 6664426d7c Issue #3137: Don't ignore errors at startup, especially a keyboard interrupt
(SIGINT). If an error occurs while importing the site module, the error is
printed and Python exits. Initialize the GIL before importing the site
module.
2010-03-10 22:30:19 +00:00
Florent Xicluna 4d42f2b4d1 #7772: Fix test_py3kwarn. Now the test suite could pass with "-3" flag. 2010-03-09 19:57:01 +00:00
Raymond Hettinger e30bc38ce9 Improve code clarity a bit. 2010-03-09 11:29:10 +00:00
Raymond Hettinger aba2293862 Have links in OrderedDicts be native Python lists instead
of a custom class with __slots__.  This simplifies the
code a bit, reduces memory consumption, improves speed,
and eliminates the need for weak reference proxies.
2010-03-09 09:58:53 +00:00
Raymond Hettinger 9bd3508530 Add nicer docstrings to namedtuples().
Provides better tooltips and looks better in help().
2010-03-09 09:01:46 +00:00
Benjamin Peterson f4803aa623 set svn:eol-style on various files 2010-03-08 22:15:11 +00:00
Florent Xicluna 47627d5164 #7624: Fix isinstance(foo(), collections.Callable) for old-style classes. 2010-03-08 15:20:28 +00:00
Florent Xicluna 6f682be82b Move some tests from test_macpath to test_genericpath.CommonTest 2010-03-08 12:39:35 +00:00
Florent Xicluna d034b32f57 On finalize, don't try to join not started process. 2010-03-08 11:01:39 +00:00
Florent Xicluna faf175385d Replace the stderr logging with assertNotEqual(returncode, 0). 2010-03-08 10:59:33 +00:00
Florent Xicluna cf741ceb69 Fix syntax: "rc != None" -> "rc is not None" 2010-03-08 10:58:12 +00:00
Florent Xicluna 52584779a6 Don't fail on a debug() statement, if the worker PID is (still) None. 2010-03-08 07:21:16 +00:00
R. David Murray 4617e5085a Issue #7143: get_payload used to strip any trailing newline from a
base64 transfer-encoded payload *after* decoding it; it no longer does.
email had a special method in utils, _bdecode, specifically to do this,
so it must have served a purpose at some point, yet it is clearly wrong
per RFC.  Fixed with Barry's approval, but no backport.  Email package
minor version number is bumped, now version 4.0.1.

Patch by Joaquin Cuenca Abela.
2010-03-08 02:04:06 +00:00
Florent Xicluna 16cd888dd9 Backport the Popen.poll() protection from subprocess to multiprocessing. See #1731717.
It should fix transient failures on test_multiprocessing.
2010-03-07 23:49:03 +00:00
Michael Foord 08611b5e55 Remove accidental print statement from last commit. 2010-03-07 23:16:20 +00:00
Michael Foord a715255a27 Fix accidental name rebinding in unittest py3k warning filtering. 2010-03-07 23:10:36 +00:00
Michael Foord 5ffa325a82 Addition of setUpClass and setUpModule shared fixtures to unittest. 2010-03-07 22:04:55 +00:00
Michael Foord 53e8eeadd6 Fix for potentials errors in constructing unittest failure messages. Plus skipped test methods no longer run setUp and tearDown (Issue 8059) 2010-03-07 20:22:12 +00:00
Florent Xicluna fc8a1ed70e Refresh the documentation for the test.test_support module. 2010-03-07 19:14:12 +00:00
Florent Xicluna 400efc2259 #2777: Try hard to make Win7 buildbot happy... 2010-03-07 17:12:23 +00:00
Mark Dickinson 154b7ad07e Issue #1530559: When packing a non-integer with any integer conversion
code using struct.pack, attempt to convert to an integer first using
the argument's __int__ method (if present).  Also raise a
DeprecationWarning for any such usage of __int__.

This fixes a regression from 2.6, where some (but not all) integer
conversion codes already used __int__.
2010-03-07 16:24:45 +00:00
Florent Xicluna c083864fc8 Do not fail if returncode is 0 on send_signal/kill/terminate, for win32 platforms.
Do not hide the KeyboardInterrupt on POSIX platforms.
2010-03-07 15:27:39 +00:00
Florent Xicluna c02bbe328d #2777: Enable test_send_signal, test_terminate and test_kill on win32 platforms. 2010-03-07 12:21:36 +00:00
Florent Xicluna 6de9e938a5 Issue #7849: Now the utility ``check_warnings`` verifies if the warnings are
effectively raised.  A new utility ``check_py3k_warnings`` deals with py3k warnings.
2010-03-07 12:18:33 +00:00
Florent Xicluna 1f3b4e12e8 Fix some py3k warnings in the standard library. 2010-03-07 12:14:25 +00:00
Senthil Kumaran 4e62949217 Reverting the change made in r78431. 2010-03-07 04:09:30 +00:00
Benjamin Peterson 6b31fd0f13 eliminate py3k warnings in argparse 2010-03-07 00:29:44 +00:00
Benjamin Peterson 8e7c1178a0 bump version to 2.7a4 2010-03-06 20:34:14 +00:00
Florent Xicluna 632df993dc Skip test_send_signal, test_kill, test_terminate on win32 platforms, for 2.7a4 release. 2010-03-06 19:43:41 +00:00
Florent Xicluna 985478dbbb Minor tweaking of previous r78734, and add a NEWS entry. 2010-03-06 18:52:52 +00:00
Florent Xicluna dc1531c5c4 Create test_genericpath.CommonTest and reuse it to test other path modules. 2010-03-06 18:07:18 +00:00
Florent Xicluna 58526417ed Do not print the header lines when running a single test. 2010-03-06 17:24:36 +00:00
Vinay Sajip 1adbee226e Added checks for tuples in dictConfig. 2010-03-06 15:56:03 +00:00
Vinay Sajip d45a278b93 Added schema version test in dictConfig. 2010-03-06 15:12:08 +00:00