Commit Graph

810 Commits

Author SHA1 Message Date
Moshe Zadka fc3fc337d0 Checking in patch #103478 -- makes popen2 and fork1 tested on BeOS.
Tested for not breaking builds on Linux.
2001-01-30 18:35:32 +00:00
Jeremy Hylton 251ef9666e Fix test for free ref to global. This test should have caught a
recently fixed bug, but it checked for the wrong answer.
2001-01-30 01:26:53 +00:00
Jeremy Hylton ac25a38841 add test for illegal imports 2001-01-30 01:25:56 +00:00
Marc-André Lemburg fde66e1bcc Fixed .capitalize() method of Unicode objects to work like the
corresponding string method. Added tests for this too.

Patch written by Marc-Andre Lemburg. Copyright assigned to Guido van Rossum.
2001-01-29 11:14:16 +00:00
Moshe Zadka 497671e094 The one thing I love more then writing code is deleting code.
* Removed func_hash and func_compare, so they can be treated as immutable
  content-less objects (address hash and comparison)
* Added tests to that affect to test_funcattrs (also testing func_code
  is writable)
* Reverse meaning of tests in test_opcodes which checked identical code
  gets identical functions
2001-01-29 06:21:17 +00:00
Skip Montanaro 080c99745f added several more urlencode test cases - part of patch 103391 2001-01-28 21:12:22 +00:00
Fred Drake 64d42c5bb1 Added tests for new signature of new.instance().
Use test_support.verify() where applicable.
2001-01-28 03:57:39 +00:00
Martin v. Löwis 2bcb32372c Except HierarchyRequestErr instead of TypeError. 2001-01-27 09:17:55 +00:00
Jeremy Hylton 619eea6821 PEP 227 implementation
test_new: new.code() noew takes two more arguments
test_grammer: Add a bunch of test cases for lambda (not really PEP 227 related)
2001-01-25 20:12:27 +00:00
Jeremy Hylton 4588c78faf PEP 227 implementation
New tests cases for nested scopes.
2001-01-25 20:11:23 +00:00
Jeremy Hylton 92e9f29aec add extra tests to verify that co_varnames is being set up properly
also normalize checks for syntax errors and delete commented out
definition of verify.
2001-01-25 17:03:37 +00:00
Skip Montanaro 03d9014992 added a few more __all__ lists
test___all__.py: fail silently in check_all if the module can't be imported
2001-01-25 15:29:22 +00:00
Guido van Rossum 42756df91c Fix the test output, now that escapes in repr() of string and Unicode
are different (Ping didn't test this).
2001-01-24 21:49:57 +00:00
Guido van Rossum 0fc8b74fc5 Fix the test output, now that escapes in repr() of string and Unicode
are different (Ping couldn't test this).
2001-01-24 21:46:18 +00:00
Ka-Ping Yee fa004ad36c Show '\011', '\012', and '\015' as '\t', '\n', '\r' in strings.
Switch from octal escapes to hex escapes for other nonprintable characters.
2001-01-24 17:19:08 +00:00
Fredrik Lundh 06d126803c Move uchhash functionality into unicodedata (after the recent
crop of changes, the files are small enough to do this).  Also
adds "name" and "lookup" functions to unicodedata.
2001-01-24 07:59:11 +00:00
Skip Montanaro 17ab123cf1 a few more modules get __all__ 2001-01-24 06:27:27 +00:00
Barry Warsaw 24f3acab3b It's "gopherlib" not "gopher". 2001-01-24 04:13:02 +00:00
Skip Montanaro 2dd4276559 added a few more __all__ lists
fixed typo in ihooks docstring
2001-01-23 15:35:05 +00:00
Tim Peters f87d857080 Restore alphabetic order. Also try to import rlcompleter and curses, but
don't fail if they're not available.
2001-01-23 09:50:30 +00:00
Jeremy Hylton 578ceee042 Add simple test of list comprehension that uses a name that isn't
otherwise used in the same code block.  (Not sure this is the right
place, but there is no test_list_comprehensions.py.)
2001-01-23 01:51:40 +00:00
Guido van Rossum d0f5e70016 - Use "exec ... in dict" to avoid having to walk on eggshells; locals
no don't have to start with underscore.

- Add spaces after commas in argument lists.

- Only test dbhash if bsddb can be imported.  (Wonder if there are
  more like this?)
2001-01-22 23:37:04 +00:00
Tim Peters 763cb0aa44 Typo repair. 2001-01-22 22:43:35 +00:00
Tim Peters e935816164 Reorganize pickle/cPickle testing so the tests pass regardless of the order
they're run.
2001-01-22 22:05:20 +00:00
Fred Drake d74804db41 The "user" module cannot reasonably be tested. Moved to the end (and
commented it out), and added an explanation as to *why*.

Added period to docstring.
2001-01-22 19:38:37 +00:00
Guido van Rossum 7f9b5e014b OK, changed my mind once more on this. The comparison hierarchy is
now

    None < all numeric types < all other types

so that once again

    map(max, Squares(3), Squares(2))

equals

    [0, 1, 4]
2001-01-22 19:30:07 +00:00
Guido van Rossum d9bae8b95a Numeric-smelling objects now once again compare smaller than
non-numeric ones, so 4 < None again in the 'map' test.
2001-01-22 16:01:24 +00:00
Guido van Rossum f317a18a4a Finn Bock (SF patch #103345): Avoid outdated exec form in
test_class.py.
2001-01-22 14:51:41 +00:00
Tim Peters d304f44906 Patch #103343: Allow the important test_pkg to succeed under Jython. 2001-01-21 19:51:53 +00:00
Tim Peters 08dabf0a73 Patch #103344: Sort dicts from extcall for easier comparison with Jython. 2001-01-21 18:52:02 +00:00
Tim Peters dfc538acae Whitespace normalization. 2001-01-21 04:49:16 +00:00
Skip Montanaro eccd02a40d more __all__ updates 2001-01-20 23:34:12 +00:00
Skip Montanaro e78b92a062 added some tests for urlencode 2001-01-20 20:22:30 +00:00
Skip Montanaro e99d5ea25b added __all__ lists to a number of Python modules
added test script and expected output file as well
this closes patch 103297.
__all__ attributes will be added to other modules without first submitting
a patch, just adding the necessary line to the test script to verify
more-or-less correct implementation.
2001-01-20 19:54:20 +00:00
Skip Montanaro c955f89225 docstring typo 2001-01-20 19:12:54 +00:00
Fredrik Lundh f60560626c Better error message if ucnhash cannot be found (obscure attribute
errors aren't that helpful), or doesn't contain what's expected from
it.  Also tweaked the test script so it compiles even if ucnhash is
missing.
2001-01-20 11:15:25 +00:00
Guido van Rossum 0a5f91f1d9 Now that Marc-Andre has retracted unistr(), remove the tests. 2001-01-19 21:57:52 +00:00
Guido van Rossum a8e14d4d03 Use a saner test filename, to work on Windows. 2001-01-19 21:06:50 +00:00
Barry Warsaw 2e9b396740 Add some regression tests of coredump bugs in funcobject.c 2.31. Also
added a test of a coredump that would occur when del'ing
func_defaults (put here for convenience).
2001-01-19 19:55:12 +00:00
Guido van Rossum a1374e429b Change verify() function to raise TestFailed, not AssertionError.
(I realize that I didn't really test this, because all the tests
succeed, so verify() never raised an AssertionError -- but the test
suite still succeeds, so I'm not too worried.)
2001-01-19 19:01:56 +00:00
Fredrik Lundh 2acb54a194 improved the ucnhash test a bit 2001-01-19 11:13:46 +00:00
Fredrik Lundh ee865c64da added "getcode" and "getname" methods to the ucnhash module (they're
probably more useful for the test code than for any applications, but
one never knows...)
2001-01-19 11:00:42 +00:00
Fredrik Lundh 0fdb90cafe refactored the unicodeobject/ucnhash interface, to hide the
implementation details inside the ucnhash module.

also cleaned up the unicode copyright blurb a little; Secret Labs'
internal revision history isn't that interesting...
2001-01-19 09:45:02 +00:00
Tim Peters cc58363611 urllib.py very recently changed to produce uppercase escapes, but no
corresponding changes were made to its std test.
2001-01-19 07:00:08 +00:00
Tim Peters 8880f6d3c4 Whitespace normalization. 2001-01-19 06:12:17 +00:00
Tim Peters 1a8a53d16f test_urllib is failing on Windows. I don't know why, but I can at least
change the test to give a clue about *where* it's failing.
2001-01-19 06:06:37 +00:00
Tim Peters 983874dd32 Use constructor form of "raise"; normalize <wink> docstrings. 2001-01-19 05:59:21 +00:00
Tim Peters d93c0b6a37 Jeremy's patch #103323: trivial tests of all untested modules. 2001-01-19 05:41:36 +00:00
Jeremy Hylton e1bb5f9814 make error msg more informative when test of exec fails 2001-01-19 03:26:33 +00:00
Jeremy Hylton 047e2c93e2 add test for SyntaxError on
def f(a):
        global a
2001-01-19 03:25:56 +00:00