|
| 1 | +name: Test |
| 2 | + |
| 3 | +on: [push, pull_request] |
| 4 | + |
| 5 | +jobs: |
| 6 | + build: |
| 7 | + name: python${{ matrix.python-version }}-${{ matrix.platform.python-architecture }} ${{ matrix.platform.os }} |
| 8 | + runs-on: ${{ matrix.platform.os }} |
| 9 | + strategy: |
| 10 | + max-parallel: 12 |
| 11 | + matrix: |
| 12 | + python-version: [3.5, 3.6, 3.7, 3.8] |
| 13 | + platform: [ |
| 14 | + { os: "macOS-latest", python-architecture: "x64", rust-target: "x86_64-apple-darwin" }, |
| 15 | + { os: "windows-latest", python-architecture: "x64", rust-target: "x86_64-pc-windows-msvc" }, |
| 16 | + { os: "windows-latest", python-architecture: "x86", rust-target: "i686-pc-windows-msvc" }, |
| 17 | + ] |
| 18 | + steps: |
| 19 | + - uses: actions/checkout@v2 |
| 20 | + - name: Set up Python ${{ matrix.python-version }} |
| 21 | + uses: actions/setup-python@v1 |
| 22 | + with: |
| 23 | + python-version: ${{ matrix.python-version }} |
| 24 | + - name: Install Rust |
| 25 | + uses: actions-rs/toolchain@v1 |
| 26 | + with: |
| 27 | + toolchain: nightly |
| 28 | + default: true |
| 29 | + - run: rustup set default-host ${{ matrix.platform.rust-target }} |
| 30 | + - name: Build without default features |
| 31 | + run: cargo build --no-default-features --verbose |
| 32 | + - name: Build with default features |
| 33 | + run: cargo build --verbose |
| 34 | + - name: Install test dependencies |
| 35 | + run: | |
| 36 | + python -m pip install -U pip setuptools |
| 37 | + pip install setuptools-rust pytest pytest-benchmark tox tox-venv numpy |
| 38 | + - name: Test |
| 39 | + run: ci/actions/test.sh |
| 40 | + shell: bash |
| 41 | + env: |
| 42 | + RUST_BACKTRACE: 1 |
0 commit comments