summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_b1.py
Commit message (Collapse)AuthorAgeFilesLines
* typos fixed by Rob HooftJeremy Hylton2000-06-281-1/+1
|
* Fix PR#7 comparisons of recursive objectsJeremy Hylton2000-04-141-0/+9
| | | | | Note that comparisons of deeply nested objects can still dump core in extreme cases.
* Marc-Andre's third try at this bulk patch seems to work (except thatGuido van Rossum2000-04-051-2/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | his copy of test_contains.py seems to be broken -- the lines he deleted were already absent). Checkin messages: New Unicode support for int(), float(), complex() and long(). - new APIs PyInt_FromUnicode() and PyLong_FromUnicode() - added support for Unicode to PyFloat_FromString() - new encoding API PyUnicode_EncodeDecimal() which converts Unicode to a decimal char* string (used in the above new APIs) - shortcuts for calls like int(<int object>) and float(<float obj>) - tests for all of the above Unicode compares and contains checks: - comparing Unicode and non-string types now works; TypeErrors are masked, all other errors such as ValueError during Unicode coercion are passed through (note that PyUnicode_Compare does not implement the masking -- PyObject_Compare does this) - contains now works for non-string types too; TypeErrors are masked and 0 returned; all other errors are passed through Better testing support for the standard codecs. Misc minor enhancements, such as an alias dbcs for the mbcs codec. Changes: - PyLong_FromString() now applies the same error checks as does PyInt_FromString(): trailing garbage is reported as error and not longer silently ignored. The only characters which may be trailing the digits are 'L' and 'l' -- these are still silently ignored. - string.ato?() now directly interface to int(), long() and float(). The error strings are now a little different, but the type still remains the same. These functions are now ready to get declared obsolete ;-) - PyNumber_Int() now also does a check for embedded NULL chars in the input string; PyNumber_Long() already did this (and still does) Followed by: Looks like I've gone a step too far there... (and test_contains.py seem to have a bug too). I've changed back to reporting all errors in PyUnicode_Contains() and added a few more test cases to test_contains.py (plus corrected the join() NameError).
* Add tests for float() and complex() with string args (Nick/StephanieGuido van Rossum1999-03-251-0/+2
| | | | Lockwood).
* Added a new test for old filter() memory leakBarry Warsaw1999-01-281-0/+17
|
* Nannified, and re-indented with 4 spaces.Guido van Rossum1998-08-101-88/+88
|
* Improved test set for int() and long() string conversions.Guido van Rossum1998-06-301-0/+59
|
* With the recent change that makes numbers compare smaller than anything,Guido van Rossum1998-06-111-3/+3
| | | | the outcome of the test for max has changed.
* Added tests of the new builtin functions issubclass() and isinstance()Barry Warsaw1997-08-221-0/+36
|
* Fix hex tests for 64-bit machines.Guido van Rossum1997-05-141-1/+3
|
* Added test of complex() (that catches a bug in 1.4!).Guido van Rossum1997-03-311-0/+39
| | | | | Added test that ensures that int() and long() truncate float numbers towards zero.
* updated the hex(-16) test since hex() of a signed literal has changed.Barry Warsaw1997-01-131-1/+1
|
* avoid math, don't abort when overflow check failsGuido van Rossum1995-03-041-1/+5
|
* * Lib/test/test_b1.py: test eval() and execfile() with globals,Guido van Rossum1995-01-021-0/+13
| | | | locals arguments
* Test new __import__ module, test reload of built-in module, testGuido van Rossum1994-12-301-0/+8
| | | | has_key() on empty dictionary
* more complete tests of built-in functionsGuido van Rossum1994-11-101-0/+44
|
* Merge alpha100 branch back to main trunkGuido van Rossum1994-08-011-0/+24
|
* * test_*.py: new lambda syntax (also affects tests for filter, map,Guido van Rossum1993-11-301-13/+8
| | | | | | | | | | reduce) * ftplib.py: added default callback for retrlines; added dir() method * ftplib.py: don't return self in self.connect(); added hack so that if 'CDUP' is not understood, 'CWD ..' is tried. * ftplib.py: second method called init() should have been called connect(); if __init__ sees more than one argument, it will also try to login().
* * string.py: added rindex(), rfind(); changed index() to interpretGuido van Rossum1993-11-081-0/+39
| | | | | | | | | | | negative start indices starting from the right. * ftplib.py: debug() -> set_debuglevel(); change demo to use __init__(). * os.py: added execl, execlp, and execvp. * lambda.py: removed (now that we have built-in map, reduce, bagof, lambda) * test_b{1,2}.py, testall.out: added tests for bagof, lambda, map, reduce * commands.py: use os, not posix * test_grammar.py: make it easy to disable non-portable int overflow tests * dis.py: don't abuse range()
* added builtin b/w compat module.Guido van Rossum1993-10-221-9/+1
| | | | changed testing of exec.
* * os.py: _exit doesn't exist in all variations of posixGuido van Rossum1993-01-261-6/+10
| | | | * Added fcmp() to test_support.py and use it in test*.py
* Added some new tests and two new files for testing: test_types.pyGuido van Rossum1992-11-271-0/+23
| | | | | (testing operations on built-in types) and autotest.py (automatic regression testing).
* Initial revisionGuido van Rossum1992-01-271-0/+127