1212 fail-fast : false
1313 matrix :
1414 os : [windows, ubuntu, macos]
15- python : [3. 6, 3. 7, 3. 8, 3. 9]
15+ pyver_minor : [6, 7, 8, 9]
1616 platform : [x64]
1717 shutdown_mode : [Normal, Soft]
18+ include :
19+ - os : ubuntu
20+ pyver_minor : 6
21+ dll_suffix : m
22+ - os : ubuntu
23+ pyver_minor : 7
24+ dll_suffix : m
25+
26+ - os : macos
27+ dll_prefix : lib
28+ dll_pyver_major : ' 3.'
29+ dll_suffix : m
30+ - os : ubuntu
31+ dll_prefix : lib
32+ dll_pyver_major : ' 3.'
33+ - os : windows
34+ dll_pyver_major : ' 3'
35+
36+ - os : ubuntu
37+ dll_ext : .so
38+ - os : windows
39+ dll_ext : .dll
40+ - os : macos
41+ dll_ext : .dylib
1842
1943 env :
2044 PYTHONNET_SHUTDOWN_MODE : ${{ matrix.SHUTDOWN_MODE }}
@@ -32,10 +56,10 @@ jobs:
3256 - name : Setup .NET
3357 uses : actions/setup-dotnet@v1
3458
35- - name : Set up Python ${{ matrix.python }}
59+ - name : Set up Python 3. ${{ matrix.pyver_minor }}
3660 uses : actions/setup-python@v2
3761 with :
38- python-version : ${{ matrix.python }}
62+ python-version : 3. ${{ matrix.pyver_minor }}
3963 architecture : ${{ matrix.platform }}
4064
4165 - name : Install dependencies
@@ -47,16 +71,28 @@ jobs:
4771 python setup.py configure
4872 pip install -v .
4973
74+ # TODO this should be gone once clr module sets PythonDLL or preloads it
75+ - name : Python Tests
76+ 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+
5081 - name : Python Tests
5182 run : pytest
83+ if : ${{ matrix.os == 'macos' }}
5284
5385 - name : Embedding tests
5486 run : dotnet test --runtime any-${{ matrix.platform }} src/embed_tests/
5587 if : ${{ matrix.os != 'macos' }} # Not working right now, doesn't find libpython
88+ env :
89+ PYTHONNET_PYDLL : ${{ matrix.DLL_PREFIX }}python${{matrix.DLL_PYVER_MAJOR}}${{matrix.PYVER_MINOR}}${{matrix.DLL_SUFFIX}}${{matrix.DLL_EXT}}
5690
5791 - name : Python tests run from .NET
5892 run : dotnet test --runtime any-${{ matrix.platform }} src/python_tests_runner/
5993 if : ${{ matrix.os == 'windows' }} # Not working for others right now
94+ env :
95+ PYTHONNET_PYDLL : ${{ matrix.DLL_PREFIX }}python${{matrix.DLL_PYVER_MAJOR}}${{matrix.PYVER_MINOR}}${{matrix.DLL_SUFFIX}}${{matrix.DLL_EXT}}
6096
6197 # TODO: Run perf tests
6298 # TODO: Run mono tests on Windows?
0 commit comments