Commit Graph

20 Commits

Author SHA1 Message Date
Tim Peters c885443479 Stop producing or using OverflowWarning. PEP 237 thought this would
happen in 2.3, but nobody noticed it still was getting generated (the
warning was disabled by default).  OverflowWarning and
PyExc_OverflowWarning should be removed for 2.5, and left notes all over
saying so.
2004-08-25 02:14:08 +00:00
Martin v. Löwis a94568a753 Patch #734231: Update RiscOS support. In particular, correct
riscospath.extsep, and use os.extsep throughout.
2003-05-10 07:36:56 +00:00
Barry Warsaw 408b6d34de Complete the absolute import patch for the test suite. All relative
imports of test modules now import from the test package.  Other
related oddities are also fixed (like DeprecationWarning filters that
weren't specifying the full import part, etc.).  Also did a general
code cleanup to remove all "from test.test_support import *"'s.  Other
from...import *'s weren't changed.
2002-07-30 23:27:12 +00:00
Tim Peters d392506c43 Tighten up some warning filters, and break some dependencies on the
order in which the tests are normally run.
2002-04-16 01:27:44 +00:00
Finn Bock aa3dc45658 Enable support for jython:
1. Acknowledge the welknown difference that jython
allows continue in the finally clause.

2. Avoid using _testcapi when running with jython.

This closes patch "[ #490417 ] Jython and test_exceptions"
2001-12-08 10:15:48 +00:00
Jeremy Hylton ede049b2d3 Add tests for new PyErr_NormalizeException() behavior
Add raise_exception() to the _testcapi module.  It isn't a test, but
the C API exists only to support test_exceptions.  raise_exception()
takes two arguments -- an exception class and an integer specifying
how many arguments it should be called with.

test_exceptions uses BadException() to test the interpreter's behavior
when there is a problem instantiating the exception.  test_capi1()
calls it with too many arguments.  test_capi2() causes an exception to
be raised in the Python code of the constructor.
2001-09-26 20:01:13 +00:00
Guido van Rossum 83b120d690 Turn OverflowWarning into an error locally, in order to make the
OverflowError test succeed.
2001-08-23 03:23:03 +00:00
Barry Warsaw b9c1d3dedf reload(exceptions) should not raise an ImportError, but should act
just like reload(sys).  Test that this is so.  Closes SF bug #422004.
2001-08-13 23:07:00 +00:00
Jeremy Hylton 3faa52ecc4 Allow 'continue' inside 'try' clause
SF patch 102989 by Thomas Wouters
2001-02-01 22:48:12 +00:00
Fred Drake 2e6d25c5bb Use 4-space indents. 2000-10-23 17:00:30 +00:00
Fred Drake 72e48bd05f Add test cases to make sure we get the right SyntaxError message for
various illegal uses of "continue".
2000-09-08 16:32:34 +00:00
Barry Warsaw 3a9d0611fb Applying patch #100994 to allow JPython to use more of the standard
Python test suite.  Specifically,

- import time instead of strop in test_b1

- test for ClassType of exceptions using isinstance instead of
  equality in test_exceptions

- remove __builtins__ from dir() output in test_pkg

test_pkg output needs to be regenerated.
2000-09-01 06:53:52 +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 56c807d318 add minimal test of exception use. verify that each exception can be
raised, caught, and converted to a string.
2000-06-20 18:52:57 +00:00
Barry Warsaw 992cb8ab53 Added a test to catch the base class. 2000-05-25 23:16:54 +00:00
Guido van Rossum 41360a4696 Mass check-in after untabifying all files that need it. 1998-03-26 19:42:58 +00:00
Barry Warsaw 6ed41a0a87 Expanded r() function to handle class exceptions. 1997-08-29 21:58:25 +00:00
Guido van Rossum e2cb7274ea exec() -> exec 1995-08-11 14:24:47 +00:00
Guido van Rossum 9ea0fbc6de Unmerged except and finally clauses 1992-05-06 11:39:49 +00:00
Guido van Rossum 3bead0984c Initial revision 1992-01-27 17:00:37 +00:00