Skip to content

Commit 8980494

Browse files
committed
Fix broken actions
1 parent 271fbfb commit 8980494

File tree

4 files changed

+20
-38
lines changed

4 files changed

+20
-38
lines changed

.github/workflows/test.yml renamed to .github/workflows/ci.yml

Lines changed: 18 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Test
1+
name: CI
22

33
on:
44
push:
@@ -51,20 +51,20 @@ jobs:
5151
run: cargo build --no-default-features --verbose
5252
- name: Build with default features
5353
run: cargo build --verbose
54-
- name: Install numpy and poetry
55-
run: pip install numpy poetry
54+
- name: Install test dependencies
55+
run: |
56+
python -m pip install --upgrade pip
57+
pip install maturin numpy poetry
5658
- name: Run cargo test
5759
run: cargo test --verbose
5860
- name: Test Examples
5961
run: |
60-
for example_dir in examples/*; do
61-
if [ $example != 'examples/linalg' ]; then
62-
pushd $example_dir
63-
poetry install
64-
poetry run maturin develop
65-
poetry run pytest
66-
popd
67-
fi
62+
for example_dir in 'examples/simple-extension'; do
63+
pushd $example_dir && \
64+
poetry install && \
65+
poetry run maturin develop && \
66+
poetry run pytest && \
67+
popd
6868
done
6969
shell: bash
7070
env:
@@ -80,21 +80,17 @@ jobs:
8080
python-version: 3.8
8181
- name: Install gfortran
8282
run: |
83-
apt update
84-
apt install -y gfortran
83+
sudo apt install -y gfortran
8584
- name: Install Rust
8685
uses: actions-rs/toolchain@v1
8786
with:
8887
toolchain: stable
8988
default: true
90-
- run: rustup set default-host ${{ matrix.platform.rust-target }}
91-
- name: Install numpy and poetry
92-
run: pip install numpy poetry
89+
- name: Install maturin and poetry
90+
run: pip install maturin poetry
9391
- name: Test Examples
9492
run: |
95-
cd examples/ndarray-linalg
96-
poetry install
97-
poetry run maturin develop
98-
poetry run pytest
99-
env:
100-
RUST_BACKTRACE: 1
93+
cd examples/linalg && \
94+
poetry install && \
95+
poetry run maturin develop && \
96+
poetry run pytest

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
rust-numpy
22
===========
3-
[![Actions Status](https://github.com/pyo3/rust-numpy/workflows/Test/badge.svg)](https://github.com/pyo3/rust-numpy/actions)
3+
[![Actions Status](https://github.com/pyo3/rust-numpy/workflows/CI/badge.svg)](https://github.com/pyo3/rust-numpy/actions)
44
[![Crate](http://meritbadge.herokuapp.com/numpy)](https://crates.io/crates/numpy)
55
[![minimum rustc 1.39](https://img.shields.io/badge/rustc-1.39+-blue.svg)](https://rust-lang.github.io/rfcs/2495-min-rust-version.html)
66

ci/actions/test.sh

Lines changed: 0 additions & 14 deletions
This file was deleted.

examples/linalg/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ crate-type = ["cdylib"]
1010

1111
[dependencies]
1212
numpy = { path = "../.." }
13-
ndarray = ">= 0.13"
13+
ndarray = "0.13"
1414
ndarray-linalg = { version = "0.12.1", features = ["openblas-static"] }
1515

1616
[dependencies.pyo3]

0 commit comments

Comments
 (0)