You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/actions/test-py/action.yml
+8-3Lines changed: 8 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,10 @@ inputs:
4
4
package:
5
5
description: "Package to run the tests for."
6
6
required: true
7
+
version:
8
+
description: "Python version to use for the test."
9
+
required: false
10
+
default: "3.8"
7
11
coverage:
8
12
description: "Generate coverage report from running the tests, ON or OFF, default OFF."
9
13
required: false
@@ -38,14 +42,15 @@ runs:
38
42
with:
39
43
name: python-wheels-simulation
40
44
path: pycode/wheelhouse
41
-
- name: Set up Python 3.8
45
+
- name: Set up Python ${{ inputs.version }}
42
46
uses: actions/setup-python@v4
43
47
with:
44
-
python-version: 3.8
48
+
python-version: ${{ inputs.version }}
45
49
- name: Install Python Wheels
46
50
shell: bash
47
51
run: |
48
-
for pkg in `ls pycode/wheelhouse/*cp38*.whl`; do python -m pip install $pkg; done # packages that contain native extensions are version specific
52
+
export PYTHON_VERSION_NO_DOT=$(echo "${{ inputs.version }}" | sed 's/\.//g')
53
+
for pkg in `ls pycode/wheelhouse/*cp$PYTHON_VERSION_NO_DOT*.whl`; do python -m pip install $pkg; done # packages that contain native extensions are version specific
49
54
for pkg in `ls pycode/wheelhouse/*py3*.whl`; do python -m pip install $pkg; done # pure python packages are not version specific
0 commit comments