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

Suggestion: use pytest-xdist to speed up pytest #38273

Open
SubaruArai opened this issue Aug 21, 2023 · 1 comment
Open

Suggestion: use pytest-xdist to speed up pytest #38273

SubaruArai opened this issue Aug 21, 2023 · 1 comment

Comments

@SubaruArai
Copy link
Contributor

Currently, the CI and unit testing uses pytest, which runs the tests sequentially. Here's a brief look of what we can expect if we run pytest concurrently using pytest-xdist:

Potential speedup

test condition GHA (2vCPU) i5-8265U with 4vCPU
1 core 3:30 2:21
n cores 2:01 1:02

Drawbacks

The text output will change, and -s option (stdout capture) will not work. As a consequence, log folding will not work, either.

@SubaruArai
Copy link
Contributor Author

If we really want to keep the full output and folding, we can add pytest-xdist to requirements.txt, and only change the docs for local testing.

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

No branches or pull requests

1 participant