This is an automated email from the ASF dual-hosted git repository.
chengpan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kyuubi.git
The following commit(s) were added to refs/heads/master by this push:
new 78e104d18 [KYUUBI #6281][PY] Speed up testing with xdist plugin
78e104d18 is described below
commit 78e104d18b467dff5c97516c9dbe541eb8f7f276
Author: Harry <[email protected]>
AuthorDate: Wed May 8 11:43:39 2024 +0800
[KYUUBI #6281][PY] Speed up testing with xdist plugin
# :mag: Description
## Issue References ๐
This pull request fixes #6281
Following up to #6343 , this PR adds `pytest-xdist` plugin to speed up
python client unit testing
## Types of changes :bookmark:
- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to change)
## Test Plan ๐งช
#### Behavior Without This Pull Request :coffin:
Running tests usually takes ~10 mins
#### Behavior With This Pull Request :tada:
Running tests can take up to 5 mins
#### Related Unit Tests
---
# Checklist ๐
- [ ] This patch was not authored or co-authored using [Generative
Tooling](https://www.apache.org/legal/generative-tooling.html)
**Be nice. Be informative.**
Closes #6369 from sudohainguyen/ci/speed-up-test.
Closes #6281
f0ce55719 [Harry] [KYUUBI #6281][PY] Speed up testing with xdist plugin
Authored-by: Harry <[email protected]>
Signed-off-by: Cheng Pan <[email protected]>
---
python/dev_requirements.txt | 1 +
python/setup.cfg | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/python/dev_requirements.txt b/python/dev_requirements.txt
index 333b76eb4..0360ab6d1 100644
--- a/python/dev_requirements.txt
+++ b/python/dev_requirements.txt
@@ -4,6 +4,7 @@ mock==2.0.0
pycodestyle==2.3.1
pytest==7.4.4
pytest-cov==5.0.0
+pytest-xdist==3.5.0
# actual dependencies: let things break if a package changes
sqlalchemy>=1.3.0
diff --git a/python/setup.cfg b/python/setup.cfg
index a26237aac..c1a9299b9 100644
--- a/python/setup.cfg
+++ b/python/setup.cfg
@@ -2,7 +2,7 @@
tag_build =
[tool:pytest]
-addopts = --tb=short --cov pyhive --cov-report html --cov-report term
+addopts = -n 4 --tb=short --cov pyhive --cov-report html --cov-report term
norecursedirs = env
python_files = test_*.py
filterwarnings =