aboutsummaryrefslogtreecommitdiff
path: root/.travis.yml
blob: 4ac52fb423ed231f04f030d3b23e835d027229e1 (plain)
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
# Travis is only used to test ARM64 Linux

dist: focal
sudo: true
language: rust
git:
  submodules: false

rust: stable

env:
  global:
    - RUST_BACKTRACE=1
    # absl deadlock detection performs poorly on arm, so we build it release
    # mode to skip the check. Enabling debug-assertions to get safer test
    # results.
    - RUSTFLAGS="--deny=warnings -C debug-assertions"
    - TEST_BIND=1

addons:
  apt:
    update: true
    packages:
      - libunwind-dev

jobs:
  include:
  - os: linux
    arch: arm64-graviton2
    vm: virt
    before_script:
      - cargo xtask submodule
      - export GRPC_VERSION=1.38.0
      - export PATH="$PATH:$HOME/.cache/bin:$HOME/.cargo/bin"
      - which cmake && cmake --version && openssl version
      - eval "$(gimme stable)"
    script:
      - if [[ $TRAVIS_OS_NAME == "linux" ]] && [[ $TRAVIS_RUST_VERSION == "stable" ]]; then
          rustup component add rustfmt && cargo fmt --all -- --check;
          env TEST_BIND=0 cargo xtask bindgen && git diff --exit-code HEAD;
        fi
      - cargo xtask bindgen
      - cargo build --no-default-features
      - cargo build --no-default-features --features protobuf-codec
      - cargo build --no-default-features --features prost-codec
      - cargo build
      - travis_wait 40 cargo test --release --all
  - os: linux
    arch: arm64-graviton2
    vm: virt
    before_script:
      - cargo xtask submodule
      - export GRPC_VERSION=1.38.0
      - export PATH="$PATH:$HOME/.cache/bin:$HOME/.cargo/bin"
      - sudo apt-get update && sudo apt-get -y install libssl-dev
      - which cmake && cmake --version && openssl version
      - eval "$(gimme stable)"
    script:
      - travis_wait 40 cargo test --release --features "openssl-vendored" --all