[ENH] in check_estimator
and run_tests
replace return_exceptions
arg with raise_exceptions
, with deprecation
#4030
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR changes the
return_exceptions
argument in some testing utilities toraise_exceptions
, with deprecation (for 0.17.0).Affected functions are
check_estimator
, andQuickTester.run_tests
.The reason for the change is that an argument
raise_exceptions
is much clearer to the user in semantics and function thanreturn_exceptions
. Since, in common user perception,raise_exceptions
is "what happens" in comparison to a baseline case of it not happening.It also becomes consistent with arguments in the testing module, e.g., conditional fixture generation functionality such as
create_conditional_fixtures_and_names
where the argument is already calledraise_exceptions
.Also changes any internal references to the argument to the post-deprecation state.