mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-19 00:00:09 +02:00
This change adds an extension trait to `BufStream` and puts the core trait behind a feature flag for optional use. This mainly adds the additional functions in an extension trait to allow the user to select if they want just the core trait or the fully featured version. Now the user can add the core feature to _not_ include the extension trait. By deafult, this feature is disabled.
131 lines
3.9 KiB
YAML
131 lines
3.9 KiB
YAML
---
|
|
language: rust
|
|
sudo: false
|
|
addons:
|
|
apt:
|
|
packages:
|
|
# to x-compile miniz-sys from sources
|
|
- gcc-multilib
|
|
|
|
matrix:
|
|
include:
|
|
- rust: stable
|
|
- rust: beta
|
|
- rust: nightly
|
|
env: ALLOW_FAILURES=true
|
|
- os: osx
|
|
- env: TARGET=i686-unknown-linux-gnu
|
|
|
|
# This represents the minimum Rust version supported by Tokio. Updating this
|
|
# should be done in a dedicated PR and cannot be greater than two 0.x
|
|
# releases prior to the current stable.
|
|
#
|
|
# Tests are not run as tests may require newer versions of rust.
|
|
- rust: 1.26.0
|
|
script: |
|
|
cargo check --all
|
|
|
|
# Test combinations of enabled features.
|
|
- rust: stable
|
|
script: |
|
|
shopt -s expand_aliases
|
|
alias check="cargo check --no-default-features"
|
|
check
|
|
check --features codec
|
|
check --features fs
|
|
check --features io
|
|
check --features reactor
|
|
check --features rt-full
|
|
check --features tcp
|
|
check --features timer
|
|
check --features udp
|
|
check --features uds
|
|
|
|
# Test the async / await preview. We don't want to block PRs on this failing
|
|
# though.
|
|
- rust: nightly
|
|
env: ALLOW_FAILURES=true
|
|
script: |
|
|
cd tokio-async-await
|
|
cargo check --all
|
|
|
|
# This runs TSAN against nightly and allows failures to propagate up.
|
|
- rust: nightly-2018-11-18
|
|
env: TSAN=yes
|
|
script: |
|
|
set -e
|
|
# Make sure the benchmarks compile
|
|
cargo build --benches --all
|
|
|
|
export ASAN_OPTIONS="detect_odr_violation=0 detect_leaks=0"
|
|
export TSAN_OPTIONS="suppressions=`pwd`/ci/tsan"
|
|
export RUST_BACKTRACE=1
|
|
|
|
# === tokio-timer ====
|
|
|
|
# Run address sanitizer
|
|
RUSTFLAGS="-Z sanitizer=address" \
|
|
cargo test -p tokio-timer --test hammer --target x86_64-unknown-linux-gnu
|
|
|
|
# Run thread sanitizer
|
|
RUSTFLAGS="-Z sanitizer=thread" \
|
|
cargo test -p tokio-timer --test hammer --target x86_64-unknown-linux-gnu
|
|
|
|
# === tokio-threadpool ====
|
|
|
|
# Run address sanitizer
|
|
RUSTFLAGS="-Z sanitizer=address" \
|
|
cargo test -p tokio-threadpool --tests --target x86_64-unknown-linux-gnu
|
|
|
|
# Run thread sanitizer
|
|
RUSTFLAGS="-Z sanitizer=thread" \
|
|
cargo test -p tokio-threadpool --tests --target x86_64-unknown-linux-gnu
|
|
|
|
# This runs cargo +nightly doc
|
|
- name: nightly_docs
|
|
rust: nightly
|
|
env: ALLOW_FAILURES=true
|
|
script: cargo doc
|
|
|
|
allow_failures:
|
|
- rust: nightly
|
|
env: ALLOW_FAILURES=true
|
|
|
|
script: |
|
|
set -e
|
|
if [[ "$TARGET" ]]
|
|
then
|
|
rustup target add $TARGET
|
|
cargo check --all --exclude tokio-tls --target $TARGET
|
|
cargo check --tests --all --exclude tokio-tls --target $TARGET
|
|
else
|
|
# Limit the execution time of loom tests.
|
|
export LOOM_MAX_DURATION=10
|
|
cargo test --all --no-fail-fast
|
|
cargo test -p tokio-buf --no-default-features
|
|
cargo doc --all
|
|
fi
|
|
|
|
before_deploy:
|
|
- cargo doc --all --no-deps
|
|
|
|
deploy:
|
|
provider: pages
|
|
skip_cleanup: true
|
|
github_token: $GH_TOKEN
|
|
target_branch: gh-pages
|
|
local_dir: target/doc
|
|
on:
|
|
branch: master
|
|
repo: tokio-rs/tokio
|
|
rust: stable
|
|
condition: $TRAVIS_OS_NAME = "linux" && $TARGET = ""
|
|
|
|
env:
|
|
global:
|
|
- secure: iwlN1zfUCp/5BAAheqIRSFIqiM9zSwfIGcVDw/V7jHveqXyNzmCs7H58/cd90WLqonqpPX0t5GF66oTjms4v0DFjgXr/k4358qeSZaV082V3baNrVpCDHeCQV0SvKsfiYxDDJGSUL1WIUP+tqqDm4+ksZQP3LnwZojkABjWz5CBNt4kX+Wz5ZbYqtQoxyuZba5UyPY2CXJtubvCVPGMJULuUpklYxXZ4dWM2olzGgVJ8rE8udhSZ4ER4JgxB0KUx3/5TwHHzgyPEsWR4bKN6JzBjIczQofXUcUXXdoZBs23H/VhCpzKcn3/oJ8btVYPzwtdj5FmVB1aVR/gjPo2bSGi/sofq+LwL/1HJXkM+kjl8m2dLLcDBKqNYNERtVA1++LhkMWAFRgGYe8v8Ryxjiue1NF5LgAIA/fjK0uI1DELTzTf/TKrM+AtPDNTvhOft4/YD+hoImjwk6nv6PBb2TiTYnc79Qf4AZ65tv1qtsAUPuw4plLaccHQAO4ldYVXn4u9c+iisJwvovs6jo06bF3U3qtdI5gXsrI9+T25TrXvYb+IREo0MHzYEM0KlPFnscEArzC3eajuSd36ARFP3lDc+gp2RPs89iJjowms0eRyepp7Cu6XO3Cd2pfAX8AqvnmttZf4Nm51ONeiBPXPXItUkJm49MCpMJywU1IZcWZg=
|
|
|
|
notifications:
|
|
email:
|
|
on_success: never
|