Thanks to visit codestin.com
Credit goes to github.com

Skip to content

FIX silently omitted tests in test_neighbors.py #14230

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

Merged
merged 2 commits into from
Jul 2, 2019

Conversation

VarIr
Copy link
Contributor

@VarIr VarIr commented Jul 1, 2019

Reference Issues/PRs

None

What does this implement/fix? Explain your changes.

Two tests in the neighbors.tests.test_neighbors.py don't work as expected, i.e. tests are silently omitted.

  • test_neighbors_badargs contains unreachable code: isinstance(class, class) instead of isinstance(obj, class)
    (see also codecov)
  • in test_k_and_radius_neighbors_X_None not all elements of an iterable are used in a loop, but the same one over again

Any other comments?

None

Copy link
Member

@rth rth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for catching this!

@rth rth changed the title FIX silently omitted tests FIX silently omitted tests in test_neighbors.py Jul 1, 2019
@jnothman jnothman merged commit 1efbe18 into scikit-learn:master Jul 2, 2019
@jnothman
Copy link
Member

jnothman commented Jul 2, 2019

Thanks @VarIr

@VarIr VarIr deleted the neighbors_tests branch July 2, 2019 06:16
koenvandevelde pushed a commit to koenvandevelde/scikit-learn that referenced this pull request Jul 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants