-
Notifications
You must be signed in to change notification settings - Fork 54
/
Copy path.gitlab-ci.yml
68 lines (63 loc) · 1.46 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
stages:
- check
- build
- test
flake8:
image: rustdocker/rust:stable
stage: check
allow_failure: true
script:
- apt-get update
- apt-get install -y flake8
- flake8 .
cargo:build:
image: rustdocker/rust:stable
stage: build
script:
- apt-get update
- apt-get install -y capnproto libsqlite3-dev
- cargo install capnpc
- cargo build --all-features --verbose
artifacts:
paths:
- target
expire_in: 6h
only:
- master
doc:build:
image: ubuntu:latest
stage: build
script:
- cd docs
- apt-get update && apt-get install -y python3-dev python3-pip
- pip3 install --upgrade pip
- pip3 install sphinx sphinx_rtd_theme sphinxcontrib-napoleon sphinxcontrib-fulltoc pycapnp cloudpickle
- make html
pytest:
image: rustdocker/rust:stable
stage: test
script:
- apt-get update
- apt-get install -y capnproto python3-dev python3-pip libsqlite3-dev
- pip3 install --upgrade pip
- pip3 install pycapnp cloudpickle pytest pytest-timeout cbor
- useradd -ms /bin/bash nonroot
- su nonroot
- RAIN_TEST_BIN=${PWD}/target/debug/rain pytest -x -v --timeout=20
artifacts:
when: on_failure
paths:
- tests/pytests/work
expire_in: 1d
only:
- master
cargo:test:
image: rustdocker/rust:stable
stage: test
script:
- apt-get update
- apt-get install -y capnproto libsqlite3-dev
- cargo install capnpc
- cargo test --all-features
only:
- master