mirror of
https://gitlab.com/flio/rustation-ng.git
synced 2025-04-02 10:31:55 -04:00
39 lines
982 B
YAML
39 lines
982 B
YAML
# Setup a cache to cache job parts between jobs to ensure faster builds
|
|
cache:
|
|
key: "$CI_JOB_NAME"
|
|
untracked: true
|
|
paths:
|
|
- $HOME/.cargo/
|
|
- target/
|
|
|
|
# Define a yaml template for running a build and then running the tests
|
|
.cargo_test_template: &cargo_test
|
|
script:
|
|
- rustc --version && cargo --version
|
|
- cargo build
|
|
- cargo build --features "debugger"
|
|
- cargo test --verbose
|
|
|
|
# Set any required environment variables here
|
|
variables:
|
|
RUST_BACKTRACE: "FULL"
|
|
|
|
# Do any pre-flight requirements here, such as updating $PATH installing
|
|
# dependencies
|
|
before_script:
|
|
- export PATH="/root/.cargo/bin:$PATH"
|
|
|
|
# The following test: stages inherit from the test template above and configure
|
|
# the image used for the various Rust release trains
|
|
test:stable:
|
|
image: "rustdocker/rust:stable"
|
|
<<: *cargo_test
|
|
|
|
test:beta:
|
|
image: "rustdocker/rust:beta"
|
|
<<: *cargo_test
|
|
|
|
test:nightly:
|
|
image: "rustdocker/rust:nightly"
|
|
allow_failure: true
|
|
<<: *cargo_test
|