-
-
Notifications
You must be signed in to change notification settings - Fork 11.2k
TST: Replace xunit setup with methods #29596
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this PR.
These changes caused several array definitions to not be aligned anymore, could you fix those?
Hopefully this push should address your suggestions @ngoldbaum @jorenham |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good! Just a couple small suggestions.
@ngoldbaum Made the changes! Found a few other spots where the code didn't lineup and tried fixing it. |
Thanks @bwhitt7! |
This PR is related to #29552, with the goal of making NumPy's testing suite more thread safe. This PR is "testing the waters" with a test file that had a lot of simple xunit setup methods. All setup methods were replaced with methods that are manually called in each test. This makes the tests more thread safe, since xunit setup methods work strangely with threads. An example of a change:
to
With this PR, you should be able to call the tests from this file with pytest-run-parallel and have all tests successfully run in parallel threads (and also run normally without pytest-run-parallel).