Commit Graph

134 Commits

Author SHA1 Message Date
Martin Panter a850ef698e Issue #27626: Spelling fixes in docs, comments and internal names
Based on patch by Ville Skyttä.
2016-07-28 01:11:04 +00:00
Martin Panter b1d867f149 Issue #27076: Doc, comment and test function name spelling fixes
Most fixes to Doc/ and Lib/ directories by Ville Skyttä.
2016-05-26 05:28:50 +00:00
Serhiy Storchaka d4442ae53a Issue #26837: assertSequenceEqual() now correctly outputs non-stringified
differing items.  This affects assertListEqual() and assertTupleEqual().
2016-04-25 08:59:35 +03:00
Serhiy Storchaka 9b2e37f688 Marked keystrokes with the :kbd: role.
Fixed the case of the "Ctrl-" prefixes.
2015-09-12 17:47:12 +03:00
Serhiy Storchaka 049060c249 Reverted issue #24134 changes. 2015-05-16 16:21:10 +03:00
Serhiy Storchaka 2e2dcf6eac Fixed English in error message. 2015-05-06 19:21:00 +03:00
Serhiy Storchaka 7f71e04cb5 Issue #24134: assertRaises() and assertRaisesRegexp() checks are not longer
successful if the callable is None.

Added tests for assertRaises().
2015-05-06 19:10:40 +03:00
Ezio Melotti 906091b5d0 #22092: use absolute imports in unittest tests. Patch by Vajrasky Kok. 2014-08-07 03:20:22 +03:00
R David Murray 6d9117604f backport: #20145: assertRaisesRegexp now raises a TypeError on bad regex.
Previously a non-string, non-regex second argument and no callable
argument could cause the test to appear to always pass.
2014-03-25 15:29:42 -04:00
Serhiy Storchaka 9788e86096 Issue #19594: Use specific asserts in unittest tests. 2013-11-17 00:15:09 +02:00
Antoine Pitrou 5d791802c9 Issue #19352: Fix unittest discovery when a module can be reached through several paths (e.g. under Debian/Ubuntu with virtualenv). 2013-10-23 19:11:29 +02:00
Mark Dickinson 8fdd9deb45 Docstring typo fix: Arithmentic -> Arithmetic. 2013-09-09 10:32:08 +01:00
Michael Foord 050e9e5c59 Closes issue 14971.
unittest test discovery no longer gets confused when a function
has a different __name__ than its name in the TestCase class dictionary.
2013-09-08 15:34:27 +12:00
Terry Jan Reedy 0c534a4624 Silence deprecation warning in test_unittest for 'None > 1'.
This is the same change that was made in 3.x when this became an error.
2013-08-31 20:37:21 -04:00
Ezio Melotti 5dd99ebbc2 #18741: fix more typos. Patch by Févry Thibault. 2013-08-17 16:07:38 +03:00
Ezio Melotti d599142197 #18663: document that assertAlmostEqual also works when the values are equal and add tests. 2013-08-11 13:04:50 +03:00
Ezio Melotti 035ecbe2f4 #8906: document failureException, longMessage, and maxDiff in the class docstring. Patch by Boris Feld. 2013-03-29 03:42:29 +02:00
Ezio Melotti 352def0ed2 #17329: document unittest.SkipTest. Initial patch by Zachary Ware. 2013-03-27 20:11:55 +02:00
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
Andrew Svetlov 4bb142b1b7 Issue #16714: use 'raise' exceptions, don't 'throw'.
Patch by Serhiy Storchaka.
2012-12-18 21:27:37 +02:00
Ezio Melotti 9b19c4bea9 #16433: fix docstring of assertNotEqual. 2012-11-08 11:08:39 +02:00
Michael Foord bf2ad34650 Pass on parameters in unittest.TextTestResult.__init__ super call 2012-09-28 12:54:56 +01:00
Martin v. Löwis ed11a5d018 Issue #8767: Restore building with --disable-unicode.
Original patch by Stefano Taschini.
2012-05-20 10:42:17 +02:00
R David Murray 6949392b56 #14832: 'first' now really refers to first arg in unittest assertItemsEqual
This appears to have been a mixup introduced when we switched from
'expected/actual' to 'first/second'.  The problem doesn't exist
in the corresponding assertCountEqual method in Python3.
2012-05-16 14:01:03 -04: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
Benjamin Peterson 83c14fe1ee this can be done without a custom dict (also fixes #12544) 2011-07-12 19:21:42 -05: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
Benjamin Peterson 55727e1207 Merged revisions 86511 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r86511 | benjamin.peterson | 2010-11-18 08:14:43 -0600 (Thu, 18 Nov 2010) | 1 line

  reduce try block compass
........
2010-11-18 14:16:32 +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 ae1bb9a00c Typo correction. 2010-06-09 12:29:56 +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 c532c57d44 Code formatting change. 2010-06-05 23:58:40 +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 20e287caed Issue 8302. SkipTest exception is setUpClass or setUpModule is now reported as a skip rather than an error. 2010-06-05 19:38:42 +00:00
Michael Foord f2c25c5cb0 Fix unittest tests after previous commit. 2010-06-05 13:48:27 +00:00