8000 Improve CI setup and readd performance tests by filmor · Pull Request #1384 · pythonnet/pythonnet · GitHub
[go: up one dir, main page]

Skip to content

Improve CI setup and readd performance tests #1384

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Split tests into different steps
  • Loading branch information
filmor committed 8000 Feb 14, 2021
commit 076461204563fff27172e1fe2d76a507760b7f86
67 changes: 51 additions & 16 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,15 @@ name: GitHub Actions
on: [ pull_request, push ]

jobs:
build-test:
name: Build and Test
build:
name: Build
runs-on: ${{ matrix.os }}-latest
timeout-minutes: 5

strategy:
fail-fast: false
matrix:
os: [windows, ubuntu, macos]
python: ["3.6", "3.7", "3.8", "3.9"]
platform: [x64]
shutdown_mode: [Normal, Soft]

env:
PYTHONNET_SHUTDOWN_MODE: ${{ matrix.SHUTDOWN_MODE }}

steps:
- name: Set Environment on macOS
Expand Down Expand Up @@ -56,17 +50,58 @@ jobs:
run: |
python -m pythonnet.find_libpython --export | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append

- name: Python Tests (Mono)
if: ${{ matrix.os != 'windows' }}
run: pytest --runtime mono
python-tests:
name: Python Tests
needs: build
runs-on: ${{ matrix.os }}-latest
timeout-minutes: 5

- name: Python Tests (.NET Core)
run: pytest --runtime netcore
strategy:
matrix:
os: [windows, ubuntu, macos]
runtime: [mono, netcore, netfx]
exclude:
- os: windows
runtime: mono
- os: linux
runtime: netfx
- os: macos
runtime: netfx

- name: Python Tests (.NET Framework)
if: ${{ matrix.os == 'windows' }}
run: pytest --runtime netfx
steps:
- name: Python Tests
run: pytest --runtime ${{ matrix.runtime }}

domain-reload-tests:
name: Domain Reload Tests
needs: build
runs-on: ${{ matrix.os }}-latest
timeout-minutes: 5

strategy:
matrix:
os: [windows, ubuntu, macos]

steps:
- name: Python Tests
run: pytest src/domain_tests

dotnet-tests:
name: Python Tests
needs: build
runs-on: ${{ matrix.os }}-latest
timeout-minutes: 5

strategy:
matrix:
os: [windows, ubuntu, macos]
platform: [x64]
shutdown_mode: [Normal, Soft]

env:
PYTHONNET_SHUTDOWN_MODE: ${{ matrix.SHUTDOWN_MODE }}

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

Expand Down
0