Michael Foord
c36bf99189
Correction to issue 17052 fix
2013-02-11 12:53:21 +00:00
Michael Foord
cb66ee7f56
Issue 17502: unittest discovery should use self.testLoader
2013-02-10 23:59:46 +00:00
Michael Foord
77cd8aab23
Issue 15505. unittest.installHandler and non callable signal handlers
2013-01-29 22:59:02 +00:00
Michael Foord
bf2ad34650
Pass on parameters in unittest.TextTestResult.__init__ super call
2012-09-28 12:54:56 +01:00
Antoine Pitrou
3815316714
Issue #14664 : It is now possible to use @unittest.skip{If,Unless} on a test class that doesn't inherit from TestCase (i.e. a mixin).
2012-04-25 17:31:12 +02:00
Raymond Hettinger
67a3e8336f
Issue 10326: Fix regression to get test cases to pickle again.
2011-06-25 12:16:25 +02:00
Ezio Melotti
7055064bbb
Fix deprecation warnings in test_unittest.
2011-05-09 05:58:17 +03:00
Ezio Melotti
34b32d62f8
#11763 : don't use difflib in TestCase.assertMultiLineEqual if the strings are too long.
2011-04-27 09:45:46 +03:00
Michael Foord
8faa20751d
Issue #10979 . unittest stdout buffering now works for class and module fixtures.
2011-03-17 12:48:56 -04:00
Michael Foord
4c9e91a092
Issue #10242 : backport of more fixes to unittest.TestCase.assertItemsEqual
2011-03-16 20:34:53 -04:00
Ezio Melotti
c2077b0d9b
#11565 : Fix several typos. Patch by Piotr Kasprzyk.
2011-03-16 12:34:31 +02:00
Michael Foord
e6e0e26780
Issue 10242. Switching unittest.TestCase.assertItemsEqual to use a collections.Counter under the hood.
...
This fixes bugs when comparing collections of items like sets that can be sorted without raising an exception but where sorting has no meaning.
2010-12-19 15:52:56 +00:00
Michael Foord
a17f076f61
Issue 10611. SystemExit should not cause a unittest test run to exit.
2010-12-19 14:53:19 +00:00
Michael Foord
5657ff8aa0
Improvement to fix for issue 9926 to allow TestResult to be reused.
2010-12-19 14:12:23 +00:00
Ezio Melotti
c139a5683b
Merged revisions 87377 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87377 | ezio.melotti | 2010-12-18 18:31:58 +0100 (Sat, 18 Dec 2010) | 1 line
Use lowercase true/false in assertTrue/assertFalse messages.
........
2010-12-18 17:58:29 +00:00
Ezio Melotti
2623a37852
Merged revisions 86596 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r86596 | ezio.melotti | 2010-11-20 21:04:17 +0200 (Sat, 20 Nov 2010) | 1 line
#9424 : Replace deprecated assert* methods in the Python test suite.
........
2010-11-21 13:34:58 +00:00
Michael Foord
e5dc24e874
Merged revisions 86101 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r86101 | michael.foord | 2010-11-01 21:09:03 +0000 (Mon, 01 Nov 2010) | 1 line
Fix issue 9926. TestSuite subclasses that override __call__ are called correctly.
........
2010-11-01 22:11:53 +00:00
Michael Foord
94f071c715
Fix error message for comparing single line strings in unittest.TestCase.assertEqual.
...
Issue 9174
2010-07-10 13:51:42 +00:00
Michael Foord
33958b87f2
Fix issue with nested test suites debug method and module setups. (unittest)
2010-06-10 20:40:21 +00:00
Michael Foord
0fedb28951
Issue 8948. cleanup functions are not run by unittest.TestCase.debug(), plus class and module teardowns are not run by unittest.TestSuite.debug().
2010-06-08 22:44:52 +00:00
Michael Foord
db919f0188
Tests for issue 8302, skipped test in a setUpClass or a setUpModule are reported as skips rather than errors.
2010-06-05 20:59:00 +00:00
Michael Foord
c1d7c5b7fa
Tests for unittest.TestCase.maxDiff.
2010-06-05 20:33:43 +00:00
Michael Foord
f2c25c5cb0
Fix unittest tests after previous commit.
2010-06-05 13:48:27 +00:00
Michael Foord
e37d75fce2
Removed the new max_diff argument to assertSequenceEqual. All unittest.TestCase assert methods that use difflib to produce failure messages now truncate overly long messages. New class attribute unittest.TestCase.maxDiff to configure this if necessary. Issue 8351.
2010-06-05 12:10:52 +00:00
Michael Foord
0100702b9a
Issue 8351. Suppress large diffs in unittest.TestCase.assertSequenceEqual.
2010-06-05 11:23:51 +00:00
Michael Foord
53a92eb3c3
Adding a test for unittest.BaseTestSuite.
2010-05-09 09:58:25 +00:00
Michael Foord
9c164af6c3
unittest: issue 8301. Adding functions to test suites no longer crashes.
2010-05-08 17:06:25 +00:00
Michael Foord
22097e4e66
Issue 7780. Adding a test for unittest test discovery from a dotted path.
2010-05-08 13:20:07 +00:00
Michael Foord
e6f5e22123
Issue 8547 - detecting and reporting that modules have been imported from the wrong location under test discovery.
2010-05-07 23:39:38 +00:00
Benjamin Peterson
1a0ce685ab
revert r80932; it breaks windows
2010-05-07 20:45:07 +00:00
Michael Foord
ae4dde0858
Issue 8547 - detecting and reporting that modules have been imported from the wrong location under test discovery.
2010-05-07 18:16:19 +00:00
Michael Foord
4fedbce55a
Adding tests for unittest command line handling of buffer, catchbreak and failfast.
2010-05-07 15:52:05 +00:00
Michael Foord
215d394b82
Adding a test for unittest test discovery with dotted path name.
2010-05-07 15:34:08 +00:00
Michael Foord
f9ffccea56
Fix unittest tests to not abuse traceback.format_exception
2010-05-02 20:39:42 +00:00
Michael Foord
5c322ece96
Adding unittest.removeHandler function / decorator for removing the signal.SIGINT signal handler. With tests and docs.
2010-04-25 19:02:46 +00:00
R. David Murray
fb4812fb59
Issue #8263 : On freebsd6 the unittest 'break' test stops regrtest; skip it.
...
This is presumably related to issue 3864, and appears to be due
to a platform bug on freebsd6.
2010-04-17 21:59:26 +00:00
Michael Foord
f6ff26c486
unittest.result.TestResult does not create its buffers until they're used. It uses StringIO not cStringIO. Issue 8333.
2010-04-07 23:04:22 +00:00
Michael Foord
93232660bb
Another attempt at a fix for unittest.test.test_result for windows line endings
2010-04-03 02:33:55 +00:00
Michael Foord
9b4ee12e89
Cross platform unittest.TestResult newline handling when buffering stdout / stderr.
2010-04-03 02:21:39 +00:00
Michael Foord
931190b4f5
Support dotted module names for test discovery paths in unittest. Issue 7780.
2010-04-03 01:15:21 +00:00
Brian Curtin
e5aa886b44
Implement #1220212 . Add os.kill support for Windows.
...
os.kill takes one of two newly added signals, CTRL_C_EVENT and
CTRL_BREAK_EVENT, or any integer value. The events are a special case
which work with subprocess console applications which implement a
special console control handler. Any other value but those two will
cause os.kill to use TerminateProcess, outright killing the process.
This change adds win_console_handler.py, which is a script to implement
SetConsoleCtrlHandler and applicable handler function, using ctypes.
subprocess also gets another attribute which is a necessary flag to
creationflags in Popen in order to send the CTRL events.
2010-04-02 23:26:06 +00:00
Michael Foord
a04c7a0f16
Issue #8038 : Addition of unittest.TestCase.assertNotRegexpMatches
2010-04-02 22:55:59 +00:00
Michael Foord
25d7976014
unittest tests no longer replace the sys.stdout put in place by regrtest
2010-04-02 22:30:56 +00:00
Michael Foord
58c1e78806
TestResult stores original sys.stdout and tests no longer use sys.__stdout__ (etc) in tests for unittest -b command line option
2010-04-02 22:08:29 +00:00
Michael Foord
5637f04a94
Addition of -b command line option to unittest for buffering stdout and stderr during test runs.
2010-04-02 21:42:47 +00:00
Michael Foord
e6410c536c
Backport of weakref.WeakSet and tests from Python 3.
2010-03-29 20:04:23 +00:00
Michael Foord
a7e08fe3f8
Addition of delta keyword argument to unittest.TestCase.assertAlmostEquals and assertNotAlmostEquals
...
This allows the comparison of objects by specifying a maximum difference; this includes the comparing of non-numeric objects that don't support rounding.
2010-03-27 19:10:11 +00:00
Michael Foord
b35ecf4775
Rename the unittest test_suite function to not clash with a test module name (unittest.test.test_suite is now unambiguous).
2010-03-27 13:42:34 +00:00
Michael Foord
ff889396a8
A fix for running unittest tests on platforms without the audioop module (e.g. jython and IronPython)
2010-03-27 12:55:19 +00:00
Michael Foord
fa2f1cdcbb
Addition of -c command line option to unittest, to handle ctrl-c during a test run more elegantly
2010-03-26 03:18:31 +00:00