0
0
mirror of https://github.com/python/cpython.git synced 2024-12-01 11:15:56 +01:00
Commit Graph

489 Commits

Author SHA1 Message Date
Skip Montanaro
e9e5dcd4db restructured a bit and added some more content... 2000-07-19 17:19:49 +00:00
Skip Montanaro
4d06923122 make TestFailed a class exception 2000-07-19 17:14:48 +00:00
Thomas Wouters
baf2663e44 Enable extra testing now that os.isatty() is in. (Also tests os.isatty ;P) 2000-07-19 14:51:54 +00:00
Thomas Wouters
7e47402264 Spelling fixes supplied by Rob W. W. Hooft. All these are fixes in either
comments, docstrings or error messages. I fixed two minor things in
test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't").

There is a minor style issue involved: Guido seems to have preferred English
grammar (behaviour, honour) in a couple places. This patch changes that to
American, which is the more prominent style in the source. I prefer English
myself, so if English is preferred, I'd be happy to supply a patch myself ;)
2000-07-16 12:04:32 +00:00
Vladimir Marangozov
5ff2ac2fa9 Break a cycle created in the saboteur() function. 2000-07-15 00:42:09 +00:00
Vladimir Marangozov
d57f5cff0e Break the cycles after testing cmp() on cyclic objects. 2000-07-14 04:32:09 +00:00
Skip Montanaro
56509a3cb8 new test for posixpath module 2000-07-12 00:20:45 +00:00
Skip Montanaro
e809b00f36 new test file for posixpath module 2000-07-12 00:20:08 +00:00
Jeremy Hylton
88887aa38e small updates to string_join:
use PyString_AS_STRING macro on local string object
    when resizing string, make sure resized string will always be big enough
    split string containing error message across two lines
add test to string_tests that causes resizing
2000-07-11 20:55:38 +00:00
Fred Drake
85f363990c Create two new exceptions: IndentationError and TabError. These are
used for indentation related errors.  This patch includes Ping's
improvements for indentation-related error messages.

Closes SourceForge patches #100734 and #100856.
2000-07-11 17:53:00 +00:00
Jeremy Hylton
fff9e20943 fix bug #42 reported by Andrew Dalke
The Compare close contains a close method that checks to see if there
is any unconsumed data in the Compare instance; i.e. if the canonical
output file contains more data than was produced by the current test
run. This method was never called, allowing differences to go
undetected.

Fix is to call close after the test is run (after __import__)

output/test_long and output/test_popen2 needed trivial changes
output/test_select contained lots of text, but test_select.py produced
    no output
2000-07-11 15:15:31 +00:00
Peter Schneider-Kamp
7a11671e8b fixed inconsistent use of tab and spaces 2000-07-11 11:24:41 +00:00
Andrew M. Kuchling
d3cf692c38 Add test of resize() method of mmap objects 2000-07-11 10:45:28 +00:00
Jeremy Hylton
20f41b6456 add more tests of string.join variants to run_method_tests 2000-07-11 03:31:55 +00:00
Jeremy Hylton
f82b04ecbb factor out test definitions to string_tests module
test_string and test_userstring run same tests for string methods
2000-07-10 17:08:42 +00:00
Guido van Rossum
1bbddd085c Added the line 'Testing UTF-16 code point order comparisons... done."
to match addition to test_unicode.py.
2000-07-10 15:06:06 +00:00
Jeremy Hylton
a5ae490584 expect message "no regression test case for method 'encode' 2000-07-10 14:14:40 +00:00
Marc-André Lemburg
d6d06ade26 Tests for new surrogate support in the UTF-8 codec. By Bill Tutt. 2000-07-07 17:48:52 +00:00
Marc-André Lemburg
b6d78fcd9c Tests for new instance support in unicode(). 2000-07-07 13:46:19 +00:00
Marc-André Lemburg
9d4674168f Added tests for the new .isalpha() and .isalnum() methods. 2000-07-05 09:46:40 +00:00
Paul Prescod
99b84bdaad Removed some tabs. 2000-07-04 03:38:10 +00:00
Fredrik Lundh
72b82ba16d - fixed grouping error bug
- changed "group" operator to "groupref"
2000-07-03 21:31:48 +00:00
Fredrik Lundh
6f01398236 - added lookbehind support (?<=pattern), (?<!pattern).
the pattern must have a fixed width.

- got rid of array-module dependencies; the match pro-
  gram is now stored inside the pattern object, rather
  than in an extra string buffer.

- cleaned up a various of potential leaks, api abuses,
  and other minors in the engine module.

- use mal's new isalnum macro, rather than my own work-
  around.

- untabified test_sre.py.  seems like I removed a couple
  of trailing spaces in the process...
2000-07-03 18:44:21 +00:00
Fred Drake
17647f5201 Compute the name of the test file so that it can be found both when this
test is run as a script and when imported via the regression test
framework.

Problem reported by Phillip Porch <root@theporch.com>.
2000-07-03 16:37:42 +00:00
Paul Prescod
ebc0473c05 Fixed test output 2000-07-01 19:17:43 +00:00
Paul Prescod
7993bcc040 Added minidom tests. 2000-07-01 14:54:16 +00:00
Guido van Rossum
54610f31cc output for openpty test 2000-07-01 03:34:14 +00:00
Guido van Rossum
a0f7e8574c Thomas Wouters: Test script for openpty() 2000-07-01 01:13:31 +00:00
Fred Drake
4c136eefab Thomas Wouters <thomas@xs4all.net>:
Test case for the pty module.
2000-06-30 23:22:35 +00:00
Fred Drake
96fee02917 Output for test_winreg2.
Someone who knows what they are doing needs to replace this with something
that makes sense -- I'm not running Windows right now.
2000-06-30 19:38:16 +00:00
Fred Drake
2658d15d45 Paul Prescod <paul@prescod.net>:
Regression test for the new winreg.py module.

[Could a Windows person someone please review this?]
2000-06-30 19:36:23 +00:00
Fredrik Lundh
4ccea94152 - reverted to "\x is binary byte"
- removed evil tabs from sre_parse and sre_compile
2000-06-30 18:39:20 +00:00
Skip Montanaro
ab1c7918f6 * added a randomize flag and corresponding -r command line argument that
allows the caller to execute the various tests in pseudo-random order -
  default is still to execute tests in the order returned by findtests().

* moved initialization of the various flag variables to the main() function
  definition, making it possible to execute regrtest.main() interactively
  and still override default behavior.
2000-06-30 16:39:27 +00:00
Guido van Rossum
2850d18615 Switch to sre for regular expression matching (the new mini-re module
is actually by Fredrik Lundh).  This will break the re tests --
Fredrik will fix this before the final release.
2000-06-30 16:25:20 +00:00
Jeremy Hylton
094c9e587c remove all prints (since the prints where of memory locations) 2000-06-30 15:13:15 +00:00
Fredrik Lundh
0640e1161f the mad patcher strikes again:
-- added pickling support (only works if sre is imported)

-- fixed wordsize problems in engine
   (instead of casting literals down to the character size,
   cast characters up to the literal size (same as the code
   word size).  this prevents false hits when you're matching
   a unicode pattern against an 8-bit string. (unfortunately,
   this broke another test, but I think the test should be
   changed in this case; more on that on python-dev)

-- added sre.purge function
   (unofficial, clears the cache)
2000-06-30 13:55:15 +00:00
Fredrik Lundh
43b3b49b5a - fixed lookahead assertions (#10, #11, #12)
- untabified sre_constants.py
2000-06-30 10:41:31 +00:00
Marc-André Lemburg
587794b386 Marc-Andre Lemburg <mal@lemburg.com>:
Added test output.
2000-06-30 10:28:32 +00:00
Marc-André Lemburg
d70141a2d9 Marc-Andre Lemburg <mal@lemburg.com>:
New test for huge formatting strings (these could cause core
dumps in previous versions).

By Trent Mick.
2000-06-30 10:26:29 +00:00
Marc-André Lemburg
6cdec2efbb New test for the ucnhash module. 2000-06-30 09:45:20 +00:00
Marc-André Lemburg
5f2e75e87c Marc-Andre Lemburg <mal@lemburg.com>:
Updated test output (the ucn tests are now in test_ucn).
2000-06-30 09:14:13 +00:00
Marc-André Lemburg
af69f15d21 Marc-Andre Lemburg <mal@lemburg.com>:
Moved tests of new Unicode Char Name support to a separate test.
2000-06-30 09:13:35 +00:00
Fredrik Lundh
b71624e698 - added support for (?P=name)
(closes #3 and #7 from the status report)
2000-06-30 09:13:06 +00:00
Fredrik Lundh
90a0791322 - pedantic: make sure "python -t" doesn't complain... 2000-06-30 07:50:59 +00:00
Fredrik Lundh
df02d0b3f0 - fixed default value handling in group/groupdict
- added test suite
2000-06-30 07:08:20 +00:00
Skip Montanaro
47c60ec9a0 Describe a bit about writing test cases for Python... 2000-06-30 06:08:35 +00:00
Jeremy Hylton
c5007aa5c3 final patches from Neil Schemenauer for garbage collection 2000-06-30 05:02:53 +00:00
Fred Drake
252af9ca27 The low-level interface is now in _winreg; update the import here. 2000-06-29 19:42:00 +00:00
Fred Drake
13634cf7a4 This patch addresses two main issues: (1) There exist some non-fatal
errors in some of the hash algorithms. For exmaple, in float_hash and
complex_hash a certain part of the value is not included in the hash
calculation. See Tim's, Guido's, and my discussion of this on
python-dev in May under the title "fix float_hash and complex_hash for
64-bit *nix"

(2) The hash algorithms that use pointers (e.g. func_hash, code_hash)
are universally not correct on Win64 (they assume that sizeof(long) ==
sizeof(void*))

As well, this patch significantly cleans up the hash code. It adds the
two function _Py_HashDouble and _PyHash_VoidPtr that the various
hashing routine are changed to use.

These help maintain the hash function invariant: (a==b) =>
(hash(a)==hash(b))) I have added Lib/test/test_hash.py and
Lib/test/output/test_hash to test this for some cases.
2000-06-29 19:17:04 +00:00
Guido van Rossum
1bfdc78c84 Skip Montanaro: modify test_socket.py to listen/connect using loopback addr 2000-06-29 17:00:54 +00:00