CI: Use recent rust image, split build/test stages

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
Maxime “pep” Buquet 2019-09-13 02:00:46 +02:00
parent 95d9ea8296
commit eba25e4acc
Signed by: pep
GPG key ID: DEDA74AEECA9D0F2

View file

@ -1,10 +1,30 @@
image: "scorpil/rust:nightly"
stages:
- build
- test
before_script:
- apt-get update -yqq
- apt-get install -yqq --no-install-recommends build-essential libssl-dev pkg-config
variables:
FEATURES: ""
test:cargo:
rust-latest-build:
stage: build
image: rust:latest
script:
- rustc --version && cargo --version
- cargo test --verbose --jobs 1 --release
- cargo build --verbose --no-default-features --features=$FEATURES
rust-nightly-build:
stage: build
image: rustlang/rust:nightly
script:
- cargo build --verbose --no-default-features --features=$FEATURES
rust-latest-test:
stage: test
image: rust:latest
script:
- cargo test --verbose --no-default-features --features=$FEATURES
rust-nightly-test:
stage: test
image: rustlang/rust:nightly
script:
- cargo test --verbose --no-default-features --features=$FEATURES