Fix for datetime tzinfo conversion #123
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Main (x64) | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
build-test: | |
name: Build and Test | |
runs-on: ${{ matrix.os }}-latest | |
timeout-minutes: 15 | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [windows, ubuntu, macos] | |
python: ["3.6", "3.7", "3.8", "3.9", "3.10"] | |
platform: [x64, x86] | |
exclude: | |
- os: ubuntu | |
platform: x86 | |
- os: macos | |
platform: x86 | |
steps: | |
- name: Set Environment on macOS | |
uses: maxim-lobanov/setup-xamarin@v1 | |
if: ${{ matrix.os == 'macos' }} | |
with: | |
mono-version: latest | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: '6.0.x' | |
- name: Set up Python ${{ matrix.python }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python }} | |
architecture: ${{ matrix.platform }} | |
- name: Install dependencies | |
run: | | |
pip install --upgrade -r requirements.txt | |
pip install numpy # for tests | |
- name: Build and Install | |
run: | | |
pip install -v . | |
- name: Set Python DLL path (non Windows) | |
if: ${{ matrix.os != 'windows' }} | |
run: | | |
python -m pythonnet.find_libpython --export >> $GITHUB_ENV | |
- name: Set Python DLL path (Windows) | |
if: ${{ matrix.os == 'windows' }} | |
run: | | |
python -m pythonnet.find_libpython --export | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append | |
- name: Embedding tests | |
run: dotnet test --runtime any-${{ matrix.platform }} --logger "console;verbosity=detailed" src/embed_tests/ | |
- name: Python Tests (Mono) | |
if: ${{ matrix.os != 'windows' }} | |
run: pytest --runtime mono | |
- name: Python Tests (.NET Core) | |
if: ${{ matrix.platform == 'x64' }} | |
run: pytest --runtime netcore | |
- name: Python Tests (.NET Framework) | |
if: ${{ matrix.os == 'windows' }} | |
run: pytest --runtime netfx | |
- name: Python tests run from .NET | |
run: dotnet test --runtime any-${{ matrix.platform }} src/python_tests_runner/ | |
- name: Perf tests | |
if: ${{ (matrix.python == '3.8') && (matrix.platform == 'x64') }} | |
run: | | |
pip install --force --no-deps --target src/perf_tests/baseline/ pythonnet==2.5.2 | |
dotnet test --configuration Release --runtime any-${{ matrix.platform }} --logger "console;verbosity=detailed" src/perf_tests/ | |
# TODO: Run mono tests on Windows? |