-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deprecate obsolete functions in unittest #50096
Comments
_makeLoader, getTestCaseNames, makeSuite and findTestCases have all had Is is ok to go straight to deprecation or should they be marked with |
I guess adding a standard DeprecationWarning is fine in these cases. |
So it turns out that unittest.makeSuite is used about 100 times More than half the time it can be replaced with Some of the other times a loader needs to be constructed and then a I'm about halfway through a patch that does this. Think it is worth (I haven't yet checked for getTestCaseNames but I imagine there will be Another possibility is to move the functions into test_support |
I'm sure Gerhard wouldn't say no to changing the sqlite3 test prefix to |
Hehe - I wasn't actually doing that, just replacing the use of the |
FYI, the sqlite3 tests have now been cleaned up (GH-20538). Remaining occurrences in Lib/test: |
I do not think that PR 28299 is correct. We want to deprecate these functions which are implemented in the unittest.loader module, not just names exported to the unittest module. |
_makeLoader is not deprecated yet, so we might keep this open a little bit more. |
It is an internal function. We can remove it without deprecation. |
How convenient :) |
Please see PR #104836 to remove them in 3.13. |
unittest
#28299Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: