-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from fitzgen/spring-cleaning
Spring cleaning
- Loading branch information
Showing
6 changed files
with
169 additions
and
11 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
sudo: false | ||
|
||
language: rust | ||
|
||
os: | ||
- linux | ||
|
||
rust: | ||
- nightly | ||
- beta | ||
- stable | ||
|
||
addons: | ||
apt: | ||
packages: | ||
- libcurl4-openssl-dev | ||
- libelf-dev | ||
- libdw-dev | ||
- binutils-dev | ||
|
||
before_script: | ||
- pip install -v 'travis-cargo<0.2' --user | ||
- if [[ -e ~/.local/bin ]]; then export PATH=~/.local/bin:$PATH; fi | ||
- echo PATH is $PATH | ||
- export SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt | ||
|
||
script: | ||
- | | ||
travis-cargo build && | ||
travis-cargo test && | ||
travis-cargo bench && | ||
travis-cargo --only stable doc | ||
after_success: | ||
- travis-cargo --only stable doc-upload | ||
- travis-cargo coveralls --no-sudo --verify | ||
- if [[ "$TRAVIS_RUST_VERSION" == "nightly" ]]; then KCOV=./kcov/build/src/kcov ./coverage; fi | ||
|
||
env: | ||
global: | ||
- TRAVIS_CARGO_NIGHTLY_FEATURE=nightly |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# `av4-fc` | ||
|
||
[![Build Status](https://travis-ci.org/psas/av4-fc.png?branch=master)](https://travis-ci.org/psas/av4-fc) [![Coverage Status](https://coveralls.io/repos/github/psas/av4-fc/badge.svg?branch=master)](https://coveralls.io/github/psas/av4-fc?branch=master) | ||
|
||
Flight controller. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/usr/bin/env bash | ||
# | ||
# Usage: | ||
# ./coverage | ||
# | ||
# Run kcov on the tests, and merge the results. | ||
# | ||
# Environment variables: | ||
# TRAVIS_JOB_ID - id for coveralls, defaults to none | ||
# KCOV - path to kcov, defaults to 'kcov' | ||
|
||
[ -n "$TRAVIS_JOB_ID" ] && COVERALLS_ID="--coveralls-id=$TRAVIS_JOB_ID" | ||
[ -z "$KCOV" ] && KCOV=kcov | ||
|
||
# Rebuild tests with dead code included, and get a list of the filenames. | ||
export RUSTFLAGS="-C link-dead-code" | ||
TEST_FILES=$(cargo test 2>&1 >/dev/null | awk '/^ Running target\/debug\// { print $2 }') | ||
|
||
KCOV_OPTS="--verify --exclude-pattern=/.cargo" | ||
OUT_DIR=target/kcov | ||
|
||
for f in $TEST_FILES; do | ||
"$KCOV" $KCOV_OPTS "$OUT_DIR" $f | ||
done | ||
"$KCOV" --merge $KCOV_OPTS $COVERALLS_ID "$OUT_DIR" "$OUT_DIR" | ||
|