Skip to content

Commit abaa42f

Browse files
committed
workaround for pytest/clr module not preloading python C API library
1 parent 478023d commit abaa42f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/main.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,18 @@ jobs:
7171
python setup.py configure
7272
pip install -v .
7373
74+
# TODO this should be gone once clr module sets PythonDLL or preloads it
7475
- name: Python Tests
7576
run: pytest
77+
if: ${{ matrix.os != 'macos' }}
78+
env:
79+
PYTHONNET_PYDLL: ${{ matrix.DLL_PREFIX }}python${{matrix.DLL_PYVER_MAJOR}}${{matrix.PYVER_MINOR}}${{matrix.DLL_SUFFIX}}${{matrix.DLL_EXT}}
80+
81+
- name: Python Tests
82+
run: pytest
83+
if: ${{ matrix.os == 'macos' }}
84+
env:
85+
PYTHONNET_PYDLL: ${{ matrix.DLL_PREFIX }}python${{matrix.DLL_PYVER_MAJOR}}${{matrix.PYVER_MINOR}}${{matrix.DLL_SUFFIX}}${{matrix.DLL_EXT}}
7686

7787
- name: Embedding tests
7888
run: dotnet test --runtime any-${{ matrix.platform }} src/embed_tests/

0 commit comments

Comments
 (0)