Skip to content
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

Improve speed of the test harness #253

Closed
amotl opened this issue Nov 25, 2020 · 3 comments
Closed

Improve speed of the test harness #253

amotl opened this issue Nov 25, 2020 · 3 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@amotl
Copy link
Member

amotl commented Nov 25, 2020

Is your feature request related to a problem?

The speed of the test harness can be tremendously improved.

Describe the solution you'd like

By following @andersy005 on behalf of pangeo-data/climpred#515, I just gave pytest-xdist a shot. The outcome is promising.

Before

time pytest

real	2m33.294s
user	1m3.104s
sys	0m12.530s

After

time pytest -n auto

real	0m44.155s
user	1m2.047s
sys	0m14.962s

cc @kmuehlbauer

@kmuehlbauer
Copy link
Collaborator

Yes, this works quite nice on a capable machine. On CI I've had different results (most CI have only 2 virtual CPU), where the gain wasn't that obvious. One thing to keep in mind, if unspecific errors are occurring, this might be due to race conditions between different parallel tests.

Thanks for sharing, @amotl .

@amotl
Copy link
Member Author

amotl commented Nov 26, 2020

Two updates on this.

@gutzbenj
Copy link
Member

I think this is more or less fixed. Other work has to be done probably on GH CI side to get this working in our pipelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
3 participants