Skip to content

Commit

Permalink
Setup x86 tests for mac and Win on github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
kngwyu committed Mar 24, 2020
1 parent 1c1d3c4 commit 35f82fd
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 27 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,32 +4,38 @@ on: [push, pull_request]

jobs:
build:
runs-on: windows-latest
name: python${{ matrix.python-version }}-${{ matrix.platform.python-architecture }} ${{ matrix.platform.os }}
runs-on: ${{ matrix.platform.os }}
strategy:
max-parallel: 4
max-parallel: 8
matrix:
python-version: [3.5, 3.6, 3.7, 3.8]
platform: [
{ os: "macOS-latest", python-architecture: "x64", rust-target: "x86_64-apple-darwin" },
{ os: "windows-latest", python-architecture: "x64", rust-target: "x86_64-pc-windows-msvc" },
{ os: "windows-latest", python-architecture: "x86", rust-target: "i686-pc-windows-msvc" },
]

steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Set Python PATH
run: ci/actions/setup
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
default: true
- run: rustup set default-host ${{ matrix.platform.rust-target }}
- name: Build
run: cargo build --verbose
- name: Install test dependencies
run: |
python -m pip install -U pip setuptools
pip install setuptools-rust pytest pytest-benchmark tox tox-venv
- name: Test
run: ci/actions/test
run: ci/actions/test.sh
shell: bash
env:
RUST_BACKTRACE: 1
3 changes: 0 additions & 3 deletions ci/actions/setup.ps1

This file was deleted.

19 changes: 0 additions & 19 deletions ci/actions/test.ps1

This file was deleted.

10 changes: 10 additions & 0 deletions ci/actions/test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

cargo test --features "$FEATURES num-bigint num-complex"
(cd pyo3-derive-backend; cargo test)

for example_dir in examples/*; do
cd $example_dir
tox -c "tox.ini" -e py
cd -
done

0 comments on commit 35f82fd

Please sign in to comment.