|
| 1 | +name: GitHub Actions |
| 2 | + |
| 3 | +on: [ push, pull_request ] |
| 4 | + |
| 5 | +jobs: |
| 6 | +build-test-oracle: |
| 7 | +name: Build and Test ARM64 |
| 8 | +runs-on: [self-hosted, linux, ARM64] |
| 9 | +timeout-minutes: 15 |
| 10 | + |
| 11 | +steps: |
| 12 | + - name: Checkout code |
| 13 | +uses: actions/checkout@v2 |
| 14 | + |
| 15 | + - name: Setup .NET |
| 16 | +uses: actions/setup-dotnet@v1 |
| 17 | +with: |
| 18 | +dotnet-version: '6.0.x' |
| 19 | + |
| 20 | + - name: Clean previous install |
| 21 | +run: | |
| 22 | + pip uninstall -y pythonnet |
| 23 | + |
| 24 | + - name: Install dependencies |
| 25 | +run: | |
| 26 | + pip install --upgrade -r requirements.txt |
| 27 | + pip install pytest numpy # for tests |
| 28 | + |
| 29 | + - name: Build and Install |
| 30 | +run: | |
| 31 | + pip install -v . |
| 32 | + |
| 33 | + - name: Set Python DLL path (non Windows) |
| 34 | +run: | |
| 35 | + python -m pythonnet.find_libpython --export >> $GITHUB_ENV |
| 36 | + |
| 37 | + - name: Embedding tests |
| 38 | +run: dotnet test --logger "console;verbosity=detailed" src/embed_tests/ |
| 39 | + |
| 40 | + - name: Python Tests (Mono) |
| 41 | +run: pytest --runtime mono |
| 42 | + |
| 43 | + - name: Python Tests (.NET Core) |
| 44 | +run: pytest --runtime netcore |
| 45 | + |
| 46 | + - name: Python tests run from .NET |
| 47 | +run: dotnet test src/python_tests_runner/ |
| 48 | + |
| 49 | + - name: Perf tests |
| 50 | +run: | |
| 51 | + pip install --force --no-deps --target src/perf_tests/baseline/ pythonnet==2.5.2 |
| 52 | + dotnet test --configuration Release --logger "console;verbosity=detailed" src/perf_tests/ |