2019-05-02 15:15:16 +10:00
|
|
|
#Adapted from https://users.rust-lang.org/t/my-gitlab-config-docs-tests/16396
|
|
|
|
|
2019-05-06 20:49:25 +10:00
|
|
|
image: 'sigp/lighthouse:latest'
|
2019-05-02 15:15:16 +10:00
|
|
|
|
|
|
|
stages:
|
|
|
|
- test
|
2019-05-08 00:52:22 +10:00
|
|
|
- document
|
2019-05-02 15:15:16 +10:00
|
|
|
|
2019-05-07 13:44:35 +10:00
|
|
|
variables:
|
2019-05-07 13:46:02 +10:00
|
|
|
CARGO_HOME: /cache/cargocache
|
2019-05-07 13:44:35 +10:00
|
|
|
|
2019-05-06 19:47:41 +10:00
|
|
|
check-fmt:
|
|
|
|
stage: test
|
|
|
|
script:
|
2019-05-07 14:24:46 +10:00
|
|
|
- cargo build --manifest-path protos/Cargo.toml
|
2019-05-06 19:47:41 +10:00
|
|
|
- cargo fmt --all -- --check
|
|
|
|
|
2019-05-06 19:45:30 +10:00
|
|
|
test-dev:
|
2019-05-02 15:15:16 +10:00
|
|
|
stage: test
|
2019-06-16 14:29:42 +10:00
|
|
|
variables:
|
|
|
|
GIT_SUBMODULE_STRATEGY: normal
|
2019-05-02 15:15:16 +10:00
|
|
|
script:
|
2019-05-06 19:45:30 +10:00
|
|
|
- cargo test --verbose --all
|
|
|
|
|
|
|
|
test-release:
|
|
|
|
stage: test
|
2019-06-16 14:29:42 +10:00
|
|
|
variables:
|
|
|
|
GIT_SUBMODULE_STRATEGY: normal
|
2019-05-06 19:45:30 +10:00
|
|
|
script:
|
|
|
|
- cargo test --verbose --all --release
|
|
|
|
|
2019-06-17 15:35:00 +10:00
|
|
|
test-fake-crypto:
|
|
|
|
stage: test
|
|
|
|
variables:
|
|
|
|
GIT_SUBMODULE_STRATEGY: normal
|
|
|
|
script:
|
|
|
|
- cargo test --manifest-path tests/ef_tests/Cargo.toml --release --features fake_crypto
|
|
|
|
|
2019-05-08 00:52:22 +10:00
|
|
|
documentation:
|
|
|
|
stage: document
|
2019-05-02 15:15:16 +10:00
|
|
|
script:
|
|
|
|
- cargo doc --no-deps
|
2019-05-08 01:20:55 +10:00
|
|
|
- aws s3 sync target/doc/ s3://lighthouse-docs.sigmaprime.io/ --exclude '.lock' --delete
|
2019-05-08 00:03:36 +10:00
|
|
|
# Configure the below when we want to have a default page (and update S3 bucket index).
|
|
|
|
# - echo '<meta http-equiv="refresh" content="0; url={{ LIBRARY NAME }}">' > public/index.html
|
2019-05-02 15:15:16 +10:00
|
|
|
only:
|
|
|
|
- master
|