Skip to content

Commit ecfd8b1

Browse files
committed
github-actions: Run pyocf test with pytest-xdist
Accorging to GitHub documentation ubuntu-lastest runner has 4 CPUs, thus set xdist to use 4 workers. Signed-off-by: Robert Baldyga <robert.baldyga@unvertical.com>
1 parent 8515b9b commit ecfd8b1

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/tests-master.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ jobs:
1818
run: |
1919
python -m pip install --upgrade pip
2020
pip install pytest
21+
pip install pytest-xdist
2122
- name: 'Build OCF library'
2223
run: cd tests/functional; make -j
2324
- name: 'Execute tests'
24-
run: cd tests/functional; python3 -m pytest
25+
run: cd tests/functional; python3 -m pytest -n 4

.github/workflows/tests-pr.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ jobs:
1515
run: |
1616
python -m pip install --upgrade pip
1717
pip install pytest
18+
pip install pytest-xdist
1819
- name: 'Build OCF library'
1920
run: cd tests/functional; make -j
2021
- name: 'Execute tests'
21-
run: cd tests/functional; python3 -m pytest
22+
run: cd tests/functional; python3 -m pytest -n 4

0 commit comments

Comments
 (0)