Skip to content

Commit eb8fa4e

Browse files
committed
Install meshpy from wheel in testing
1 parent d74e07c commit eb8fa4e

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

.github/actions/build_wheel/action.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,14 @@ runs:
1313
run: |
1414
cd ${GITHUB_WORKSPACE}
1515
${{ inputs.source-command }}
16-
pip -m build
16+
pip install build
17+
python -m build
1718
# Check if we got exactly one wheel file
1819
shopt -s nullglob
1920
files=(dist/*.whl)
2021
if [ ${#files[@]} -ne 1 ]; then
2122
echo "Expected exactly one .whl file in dist/, found ${#files[@]}"
2223
exit 1
2324
fi
25+
# Rename to fixed name so we can install the wheel
26+
mv "${files[0]}" dist/meshpy_testing.whl

.github/workflows/testing.yml

+4-1
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,17 @@ jobs:
3030
uses: actions/setup-python@v5
3131
with:
3232
python-version: ${{ matrix.python-version }}
33+
- name: Build wheel
34+
uses: ./.github/actions/build_wheel
35+
if: matrix.python-version == '3.12'
3336
- name: Run the test suite
3437
uses: ./.github/actions/run_tests
3538
with:
3639
# Test coverage and editable install with Python 3.10, otherwise we use a
3740
# non-editable installation and turn of coverage, because the coverage
3841
# only works in editable mode.
3942
install-command: >-
40-
${{ matrix.python-version == '3.10' && '-e .[dev]' || '.[dev]'}}
43+
${{ matrix.python-version == '3.10' && '-e .[dev]' || '"dist/*.whl[dev]"'}}
4144
# The single space in the empty string is required, otherwise GitHub
4245
# evaluates the if clause wrong.
4346
additional-pytest-flags: >-

0 commit comments

Comments
 (0)