Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | gh-93839: Move Lib/unttest/test/ to Lib/test/test_unittest/ (#94043) | Victor Stinner | 2022-06-21 | 1 | -1977/+0 |
| | | | | | | | | * Move Lib/unittest/test/ to Lib/test/test_unittest/ * Remove Lib/test/test_unittest.py * Replace unittest.test with test.test_unittest * Remove unittest.load_tests() * Rewrite unittest __init__.py and __main__.py * Update build system, CODEOWNERS, and wasm_assets.py | ||||
* | Simplify testing the warning filename (GH-91868) | Serhiy Storchaka | 2022-04-24 | 1 | -6/+6 |
| | | | The context manager result has the "filename" attribute. | ||||
* | bpo-45162: Revert "Remove many old deprecated unittest features" (GH-30935) | Gregory P. Smith | 2022-01-27 | 1 | -6/+63 |
| | | | | | | | | | | Revert "bpo-45162: Remove many old deprecated unittest features (GH-28268)" This reverts commit b0a6ede3d0bd6fa4ffe413ab4dfc1059201df25b. We're deferring this change until 3.12 while upstream projects that use the legacy assertion method names are fixed. See the issue for links to the discussion. Many upstream projects now have issues and PRs filed. | ||||
* | bpo-46111: Fix unittest tests in optimized mode (GH-30163) | Serhiy Storchaka | 2021-12-17 | 1 | -0/+2 |
| | |||||
* | bpo-30856: Update TestResult early, without buffering in _Outcome (GH-28180) | Serhiy Storchaka | 2021-09-19 | 1 | -14/+14 |
| | | | | | | | TestResult methods addFailure(), addError(), addSkip() and addSubTest() are now called immediately after raising an exception in test or finishing a subtest. Previously they were called only after finishing the test clean up. | ||||
* | bpo-45162: Remove many old deprecated unittest features (GH-28268) | Serhiy Storchaka | 2021-09-17 | 1 | -63/+6 |
| | | | | | | | * "fail*" and "assert*" aliases of TestCase methods. * Broken from start TestCase method assertDictContainsSubset(). * Ignored TestLoader.loadTestsFromModule() parameter use_load_tests. * Old alias _TextTestResult of TextTestResult. | ||||
* | bpo-5846: Do not use obsolete unittest functions. (GH-28303) | Serhiy Storchaka | 2021-09-13 | 1 | -1/+1 |
| | | | | Get rid of use of makeSuite() and findTestCases(). Also make test_math and test_threading_local discoverable. | ||||
* | bpo-25130: Add calls of gc.collect() in tests to support PyPy (GH-28005) | Serhiy Storchaka | 2021-08-29 | 1 | -1/+2 |
| | |||||
* | bpo-41322: Add unit tests for deprecation of test return values (GH-27846) | andrei kulakov | 2021-08-22 | 1 | -0/+20 |
| | | | | Also fix the traceback of warnings. | ||||
* | bpo-41943: Fix bug where assertLogs doesn't correctly filter messages… ↵ | Irit Katriel | 2020-11-02 | 1 | -0/+12 |
| | | | | | | | | | (GH-22565) … by level @vsajip , @pitrou Automerge-Triggered-By: GH:vsajip | ||||
* | bpo-39385: Add an assertNoLogs context manager to unittest.TestCase (GH-18067) | Kit Choi | 2020-07-01 | 1 | -0/+75 |
| | | | Co-authored-by: Rémi Lapeyre <remi.lapeyre@henki.fr> | ||||
* | bpo-29620: iterate over a copy of sys.modules (GH-4800) | kernc | 2020-06-11 | 1 | -0/+15 |
| | | | | | | | unittest.TestCase.assertWarns no longer raises a RuntimeException when accessing a module's ``__warningregistry__`` causes importation of a new module, or when a new module is imported in another thread. Patch by Kernc. | ||||
* | bpo-39450 Stripped whitespace before parsing the docstring in ↵ | Steve Cirelli | 2020-02-03 | 1 | -0/+9 |
| | | | | TestCase.shortDescription (GH-18175) | ||||
* | Fix typo in test comment (GH-11442) | Ashwin Ramaswami | 2019-05-19 | 1 | -1/+1 |
| | |||||
* | bpo-34900: Make TestCase.debug() work with subtests (GH-9707) | Bruno Oliveira | 2018-10-12 | 1 | -0/+14 |
| | |||||
* | bpo-34318: Convert deprecation warnings to errors in assertRaises() etc. ↵ | Serhiy Storchaka | 2018-08-19 | 1 | -12/+8 |
| | | | | (GH-8623) | ||||
* | Fix miscellaneous typos (#4275) | luzpaz | 2017-11-05 | 1 | -1/+1 |
| | |||||
* | Fix ref cycles in TestCase.assertRaises() (#193) | Victor Stinner | 2017-03-27 | 1 | -0/+13 |
| | | | | bpo-23890: unittest.TestCase.assertRaises() now manually breaks a reference cycle to not keep objects alive longer than expected. | ||||
* | Issue #27430: Fix typos, patch by scop. | Berker Peksag | 2016-07-01 | 1 | -1/+1 |
| | |||||
* | Issue #26837: assertSequenceEqual() now correctly outputs non-stringified | Serhiy Storchaka | 2016-04-25 | 1 | -0/+76 |
| | | | | | differing items (like bytes in the -b mode). This affects assertListEqual() and assertTupleEqual(). | ||||
* | Issue #15836: assertRaises(), assertRaisesRegex(), assertWarns() and | Serhiy Storchaka | 2015-05-21 | 1 | -0/+56 |
| | | | | | assertWarnsRegex() assertments now check the type of the first argument to prevent possible user error. Based on patch by Daniel Wagner-Hall. | ||||
* | Issue #24134: assertRaises(), assertRaisesRegex(), assertWarns() and | Serhiy Storchaka | 2015-05-16 | 1 | -4/+40 |
| | | | | | assertWarnsRegex() checks now emits a deprecation warning when callable is None or keyword arguments except msg is passed in the context manager mode. | ||||
* | Issue #24134: assertRaises(), assertRaisesRegex(), assertWarns() and | Serhiy Storchaka | 2015-05-06 | 1 | -0/+52 |
|\ | | | | | | | | | | | assertWarnsRegex() checks are not longer successful if the callable is None. Added tests for assertRaises(). | ||||
| * | Issue #24134: assertRaises(), assertRaisesRegex(), assertWarns() and | Serhiy Storchaka | 2015-05-06 | 1 | -0/+52 |
| | | | | | | | | | | | | assertWarnsRegex() checks are not longer successful if the callable is None. Added tests for assertRaises(). | ||||
* | | Issue #22894: TestCase.subTest() would cause the test suite to be stopped ↵ | Antoine Pitrou | 2014-11-23 | 1 | -0/+28 |
|\ \ | |/ | | | | | when in failfast mode, even in the absence of failures. | ||||
| * | Issue #22894: TestCase.subTest() would cause the test suite to be stopped ↵ | Antoine Pitrou | 2014-11-23 | 1 | -0/+28 |
| | | | | | | | | when in failfast mode, even in the absence of failures. | ||||
* | | Close #22756: Improve the test output for some assertEqual tests. | Robert Collins | 2014-10-29 | 1 | -5/+3 |
| | | | | | | | | | | | | These tests were undebuggable as written, and there's no testing fallacy involved in using the method we're testing to test the output of that method, so switch to that. | ||||
* | | Issue #22186: Fix typos in Lib/. | Berker Peksag | 2014-10-19 | 1 | -1/+1 |
|\ \ | |/ | | | | | Patch by Févry Thibault. | ||||
| * | Issue #22186: Fix typos in Lib/. | Berker Peksag | 2014-10-19 | 1 | -1/+1 |
| | | | | | | | | Patch by Févry Thibault. | ||||
* | | #22092: merge with 3.4. | Ezio Melotti | 2014-08-07 | 1 | -1/+1 |
|\ \ | |/ | |||||
| * | #22092: use absolute imports in unittest tests. Patch by Vajrasky Kok. | Ezio Melotti | 2014-08-07 | 1 | -1/+1 |
| | | |||||
| * | backport: #20145: assert[Raises|Warns]Regex now raise TypeError on bad regex. | R David Murray | 2014-03-25 | 1 | -0/+12 |
| | | | | | | | | | | | | | | Previously a non-string, non-regex second argument and missing callable argument could cause the test to appear to always pass. Initial patch by Kamilla Holanda. | ||||
* | | Fix typo in test method name. | Mark Dickinson | 2014-04-18 | 1 | -1/+1 |
| | | |||||
* | | #20145: assert[Raises|Warns]Regex now raise TypeError on bad regex. | R David Murray | 2014-03-23 | 1 | -0/+12 |
|/ | | | | | | | Previously a non-string, non-regex second argument could cause the test to always pass. Initial patch by Kamilla Holanda. | ||||
* | Remove commented out debugging code (remnants of issue #18996). | Serhiy Storchaka | 2013-12-10 | 1 | -2/+0 |
| | |||||
* | Close #19880: Fix a reference leak in unittest.TestCase. Explicitly break | Victor Stinner | 2013-12-09 | 1 | -0/+26 |
| | | | | reference cycles between frames and the _Outcome instance. | ||||
* | Issue #19594: Use specific asserts in unittest tests. | Serhiy Storchaka | 2013-11-16 | 1 | -6/+6 |
|\ | |||||
| * | Issue #19594: Use specific asserts in unittest tests. | Serhiy Storchaka | 2013-11-16 | 1 | -6/+6 |
| | | |||||
* | | Issue #18996: TestCase.assertEqual() now more cleverly shorten differing | Serhiy Storchaka | 2013-09-23 | 1 | -3/+34 |
| | | | | | | | | strings in error report. | ||||
* | | Issue #18937: Add an assertLogs() context manager to unittest.TestCase to ↵ | Antoine Pitrou | 2013-09-14 | 1 | -0/+96 |
| | | | | | | | | ensure that a block of code emits a message using the logging module. | ||||
* | | Issue #19013: add unittest.main() epilogs to unittest's own test modules | Antoine Pitrou | 2013-09-13 | 1 | -0/+4 |
| | | |||||
* | | #18741: merge with 3.3. | Ezio Melotti | 2013-08-17 | 1 | -1/+1 |
|\ \ | |/ | |||||
| * | #18741: fix more typos. Patch by Févry Thibault. | Ezio Melotti | 2013-08-17 | 1 | -1/+1 |
| | | |||||
* | | Issue #16997: unittest.TestCase now provides a subTest() context manager to ↵ | Antoine Pitrou | 2013-03-20 | 1 | -1/+93 |
|/ | | | | procedurally generate, in an easy way, small test instances. | ||||
* | test that TestCase doesn't get cycles | Benjamin Peterson | 2011-07-14 | 1 | -0/+9 |
| | |||||
* | #11763: merge with 3.2. | Ezio Melotti | 2011-04-27 | 1 | -0/+36 |
|\ | |||||
| * | #11763: merge with 3.1. | Ezio Melotti | 2011-04-27 | 1 | -0/+36 |
| | | |||||
* | | #11282: add back the fail* methods and assertDictContainsSubset. | Ezio Melotti | 2011-04-03 | 1 | -0/+53 |
| | | |||||
* | | #11282: merge with 3.2. | Ezio Melotti | 2011-04-03 | 1 | -4/+2 |
|\ \ | |/ | |||||
| * | #11282: the fail* methods will stay around a few more versions. | Ezio Melotti | 2011-04-03 | 1 | -4/+2 |
| | |