From 82be62678affc0e10a40a37858a08c68aa1102f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maxime=20=E2=80=9Cpep=E2=80=9D=20Buquet?= Date: Fri, 13 Sep 2019 02:22:52 +0200 Subject: [PATCH] CI: refactor .gitlab-ci.yml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Maxime “pep” Buquet --- .gitlab-ci.yml | 41 +++++++++++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 14 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index cc36abc6..544ba125 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -5,26 +5,39 @@ stages: variables: FEATURES: "" -rust-latest-build: - stage: build +.stable: image: rust:latest + +.nightly: + image: rustlang/rust:nightly + +.build: + stage: build script: - cargo build --verbose --no-default-features --features=$FEATURES +.test: + stage: test + script: + - cargo test --verbose --no-default-features --features=$FEATURES + +rust-latest-build: + extends: + - .build + - .stable + rust-nightly-build: - stage: build - image: rustlang/rust:nightly - script: - - cargo build --verbose --no-default-features --features=$FEATURES + extends: + - .build + - .nightly + rust-latest-test: - stage: test - image: rust:latest - script: - - cargo test --verbose --no-default-features --features=$FEATURES + extends: + - .test + - .stable rust-nightly-test: - stage: test - image: rustlang/rust:nightly - script: - - cargo test --verbose --no-default-features --features=$FEATURES + extends: + - .test + - .nightly