Commit graph

1486 commits

Author SHA1 Message Date
Jeremy Hylton
08a6403973 Test the unary operator changes to the compiler 2001-08-12 02:22:27 +00:00
Guido van Rossum
f73e30c3e3 Add the list of expected skips for Linux 2.x. Restructured the code a
little bit using a dictionary to avoid more code duplication as
more platforms are supported.
2001-08-12 02:22:19 +00:00
Tim Peters
a2be2d624a Move line; reported on python-dev by Mark Favas (thanks!). 2001-08-12 02:01:09 +00:00
Tim Peters
b5b7b78414 Teach regrtest which tests we *expect* to skip on Win32. Please teach it
about your platform too.
2001-08-12 01:20:39 +00:00
Jack Jansen
dbc363ce35 The test assumed that the local pathname convention for "foo" would sort before "foo/bar", which is not true on the mac (where they are "foo" and ":foo:bar", respectively; ":foo" would be fine too, but "foo" is the preferred spelling). Fixed by sorting the output. 2001-08-11 23:22:43 +00:00
Fred Drake
cd112f5546 Added tests for rich comparison operator functions.
Converted tests to PyUnit.
2001-08-11 03:21:35 +00:00
Guido van Rossum
e45763a8e6 Add test for SF bug #442833 (multiple inheritance). 2001-08-10 21:28:46 +00:00
Guido van Rossum
61cf780b6d The message accompanying the TypeError exception on a readonly
attribute changed again.
2001-08-10 21:25:24 +00:00
Guido van Rossum
6d94627f1e Allow AttributeError as well as TypeError for attribute-less objects. 2001-08-10 19:42:38 +00:00
Andrew M. Kuchling
fcfc8d5c0e Patch #441091 from Finn Bock: the more advanced flush options are not
available in java, so only use the advanced flush options if they
  are defined in the zlib module.
2001-08-10 15:50:11 +00:00
Guido van Rossum
e056e4d15c Check in a testcase for SF bug #449000: re.sub(r'\n', ...) broke. 2001-08-10 14:52:48 +00:00
Tim Peters
ab9ba27dc0 Whitespace normalization. 2001-08-09 21:40:30 +00:00
Tim Peters
c7ca3ffba3 Skip test_mhlib on Windows -- too many Unix assumptions. 2001-08-09 21:34:54 +00:00
Fred Drake
eaa77e2ca1 Added tests for operator.floordiv() and operator.truediv(). 2001-08-09 20:23:08 +00:00
Guido van Rossum
3720261729 Restore the test for 'object' that I removed when object was
uninstantiable.  All is well now.
2001-08-09 19:45:21 +00:00
Guido van Rossum
0263c80b90 Unittests for mhlib, by Nick Mathewson. 2001-08-09 18:18:08 +00:00
Martin v. Löwis
8cc965c1fb Patch #448474: Add support for tell() and seek() to gzip.GzipFile. 2001-08-09 07:21:56 +00:00
Guido van Rossum
64deef2b17 A test suite for binary operators, disguised as a rational number
class.
2001-08-08 22:27:20 +00:00
Fred Drake
c9fadf991c Add a test that xml.sax.saxutils.XMLGenerator does the right thing
when quoting attribute values that contain single & double quotes.

This provides the rest of the regression test for SF bug #440351.
2001-08-07 19:17:06 +00:00
Guido van Rossum
288cd2cb69 Fix the test so it uses IterableUserDict for the "for x in dict" test. 2001-08-07 17:50:06 +00:00
Guido van Rossum
15d86c6297 Remove the test for the 'object' type -- it can no longer be
instantiated.  (Its use as a base class is adequately tested by other
tests.)
2001-08-07 16:53:42 +00:00
Jeremy Hylton
cd738364ce silence warnings about import * 2001-08-07 16:38:19 +00:00
Greg Ward
cbce202f82 Hack to workaround bug #445984: attempt to import _socket before
starting the test suite proper.  If _socket fails to build, that will
make this test fail with an ImportError -- handled by the test harness
as "no such module _socket" -- instead of an AttributeError deep in
CGIHTTPServer.
2001-08-04 22:22:19 +00:00
Tim Peters
c173137391 Derived from SF patch #446899 Permit import of .pyw under Windows, from
David Bolen.
2001-08-04 08:12:36 +00:00
Tim Peters
e861365dab Don't use any characters C doesn't guarantee are safe for text-mode files.
This should stop the bizarre translations Jack was getting from Mac CVS.
2001-08-03 20:40:18 +00:00
Fred Drake
84bb9d8dc4 Fix stupid bug: when migrating these tests from the Zope repository, the
names of the test methods were not changed from the Zope-standard "check"
names to the Python-standard "test_" names, so the tests were not actually
being run.

Added test of hexadecimal character references as a regression check for
SF bug #445196.
2001-08-03 19:53:01 +00:00
Jack Jansen
fffd7224df The test opened the binary test data files in text mode! Fixed. 2001-08-03 13:04:03 +00:00
Fred Drake
4fd06e0170 Make sure that WeakValueDictionary[] raises KeyError instead of TypeError
for keys that are not in the dictionary.
2001-08-03 04:11:27 +00:00
Tim Peters
d342c62961 This test failed under python -O.
rewrite_file():  Delete both .pyc and .pyo leftovers, and explicitly close
the new source file after writing to it.
2001-08-02 17:23:11 +00:00
Guido van Rossum
394a47b268 Unit test for improved package import semantics.
Original by Alex Coventry (in SF patch #441791), adapted to the
standard regression test framework.
2001-08-02 14:14:20 +00:00
Tim Peters
6d6c1a35e0 Merge of descr-branch back into trunk. 2001-08-02 04:15:00 +00:00
Tim Peters
722d78f18a s/endswith/startswith/ 2001-08-01 20:23:18 +00:00
Tim Peters
66e1a254a1 Rewritten version of Finn Bock's SF patch #446907 (Allow jython to
complete test_import).
2001-08-01 19:38:56 +00:00
Tim Peters
108efac24e test_codeup should not have had an expected-output file; removing it. 2001-07-30 23:10:44 +00:00
Jeremy Hylton
b7a7731e01 Add tests for getattr() and hasattr() with non-string args 2001-07-30 22:49:11 +00:00
Jeremy Hylton
5121e7de11 Fix for SF bug [ #443866 ] Evaluating func_code causing core dump
Add test that calls eval with a code object that has free variables.
2001-07-30 21:55:29 +00:00
Jeremy Hylton
3c19ec4eab Fix when pyexpat not built
Import pyexpat first so that import error occurs when it is not
available.
2001-07-30 21:47:25 +00:00
Martin v. Löwis
3bd071e3f7 Patch #442866: Tests for codeop.py. 2001-07-30 12:30:08 +00:00
Tim Peters
33dc0a1705 One more crack at join(): stop trying to pretend this isn't a mass of
special cases.  test_pkg works again on Windows.
2001-07-27 08:09:54 +00:00
Tim Peters
4223f89edd Change ntpath.join() so that join("d:/", "/whatever") returns
d:/whatever instead of /whatever.  While I'm afraid changing isabs()
to be *consistent* with this would break lots of code, it makes
best sense for join() to do it this way.  Thanks to Alex Martelli for
pushing back on this one!
2001-07-26 21:54:37 +00:00
Tim Peters
7321ec437b SF bug #444510: int() should guarantee truncation.
It's guaranteed now, assuming the platform modf() works correctly.
2001-07-26 20:02:17 +00:00
Marc-André Lemburg
80d1dd5f3b Fix for bug #444493: u'\U00010001' segfaults with current CVS on
wide builds.
2001-07-25 16:05:59 +00:00
Fred Drake
f973c6d594 Make this test work under Windows as well. 2001-07-23 16:30:21 +00:00
Fred Drake
99e87f9e23 Test for the "glob" module, contributed by Nick Mathewson.
Heavily modified so this doesn't break on Windows.
This closes SF patch #441175.
2001-07-23 16:08:36 +00:00
Tim Peters
fa712ca1ed Whitespace normalization.
Note:  This test fails on Windows.  Don't know why yet.
2001-07-23 09:44:21 +00:00
Fred Drake
4c81d60fcb Tests for the "commands" module, contributed by Nick Mathewson.
This closes SF patch #440291.
2001-07-23 04:08:01 +00:00
Fred Drake
1586136193 New tests by Nick Mathewson, for the fpformat module.
This closes SF patch #440290.
2001-07-23 02:46:35 +00:00
Tim Peters
137759407b On WIndows, skip the part of test_dircache that can't work on Windows. 2001-07-21 02:22:14 +00:00
Tim Peters
87cc0c329e Whitespace normalization, plus:
+ test_quopri.py relied on significant trailing spaces.  Fixed.
+ test_dircache.py (still) doesn't work on Windows (directory mtime on
  Windows doesn't work like it does on Unix).
2001-07-21 01:41:30 +00:00
Fred Drake
79e75e1916 Use string.ascii_letters instead of string.letters (SF bug #226706). 2001-07-20 19:05:50 +00:00