nalgebra/.semaphore/semaphore.yml

73 lines
2.6 KiB
YAML
Raw Normal View History

2021-03-01 19:02:31 +08:00
version: v1.0
name: Rust
agent:
machine:
type: e1-standard-2
os_image: ubuntu1804
containers:
- name: main
image: 'registry.semaphoreci.com/rust:1.47'
blocks:
- name: Rustfmt
task:
jobs:
- name: run cargo fmt
commands:
- checkout
- rustup component add rustfmt
- cargo fmt -- --check
dependencies: []
- name: Clippy
2021-03-01 19:28:42 +08:00
dependencies: []
2021-03-01 19:02:31 +08:00
task:
jobs:
- name: Run clippy
commands:
2021-03-01 19:30:16 +08:00
- checkout
2021-03-01 19:02:31 +08:00
- rustup component add clippy
- cargo clippy
2021-03-01 19:36:33 +08:00
- name: Build (native)
2021-03-01 19:28:42 +08:00
dependencies: []
2021-03-01 19:02:31 +08:00
task:
jobs:
2021-03-01 19:36:33 +08:00
- name: Build nalgebra
2021-03-01 19:02:31 +08:00
commands:
2021-03-01 19:30:16 +08:00
- checkout
2021-03-01 19:02:31 +08:00
- apt-get install -y cmake gfortran libblas-dev liblapack-dev
- cargo build --no-default-features
- cargo build
- cargo build --all-features
2021-03-01 19:36:33 +08:00
- name: Build nalgebra-glm
2021-03-01 19:02:31 +08:00
commands:
2021-03-01 19:30:16 +08:00
- checkout
2021-03-01 19:02:31 +08:00
- cargo build -p nalgebra-glm --all-features
2021-03-01 19:36:33 +08:00
- name: Build nalgebra-lapack
commands:
- checkout
- apt-get install -y cmake gfortran libblas-dev liblapack-dev
- cd nalgebra-lapack
- cargo build
- name: Test (native)
2021-03-01 19:28:42 +08:00
dependencies: []
2021-03-01 19:02:31 +08:00
task:
jobs:
2021-03-01 19:36:33 +08:00
- name: Test nalgebra
2021-03-01 19:02:31 +08:00
commands:
2021-03-01 19:30:16 +08:00
- checkout
2021-03-01 19:36:33 +08:00
- 'cargo test --features arbitrary --features serde-serialize,abomonation-serialize,sparse,debug,io,compare,libm,proptest-support,slow-tests'
- name: Test nalgebra-glm
commands:
- checkout
- 'cargo test -p nalgebra-glm --features arbitrary,serde-serialize,abomonation-serialize,sparse,debug,io,compare,libm,proptest-support,slow-tests;'
- name: Test nalgebra-sparse
commands:
- checkout
- '# Manifest-path is necessary because cargo otherwise won''t correctly forward features'
- '# We increase number of proptest cases to hopefully catch more potential bugs'
- 'PROPTEST_CASES=10000 cargo test --manifest-path=nalgebra-sparse/Cargo.toml --features compare,proptest-support'
- name: Test nalgebra-sparse (slow tests)
commands:
- checkout
- '# Unfortunately, the "slow-tests" take so much time that we need to run them with --release'
- 'PROPTEST_CASES=10000 cargo test --release --manifest-path=nalgebra-sparse/Cargo.toml --features compare,proptest-support,slow-tests slow'