-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test against Specimens.jl, improve buffer perf & error msging
- Loading branch information
Roderick Bovee
committed
Sep 7, 2019
1 parent
c4ae3d9
commit 1f5ac3a
Showing
14 changed files
with
454 additions
and
229 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,35 +1,139 @@ | ||
version: 2 | ||
jobs: | ||
test: | ||
docker: | ||
- image: circleci/rust:1.37-stretch | ||
version: 2.1 | ||
|
||
executors: | ||
needletail: | ||
machine: | ||
image: ubuntu-1604:201903-01 | ||
|
||
commands: | ||
checkout_and_setup: | ||
description: "Checkout code and set up rust" | ||
steps: | ||
- checkout | ||
- restore_cache: | ||
name: restore rust install | ||
keys: | ||
- rust-stable | ||
- run: | ||
name: set up rust nightly | ||
command: | | ||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain stable | ||
echo 'export PATH=$HOME/.cargo/bin:$PATH' >> $BASH_ENV | ||
source $HOME/.cargo/env | ||
rustup show | ||
- save_cache: | ||
name: cache rust install | ||
paths: | ||
- ~/.rustup/ | ||
- ~/.cargo/ | ||
key: rust-stable | ||
- run: | ||
name: Version information | ||
command: rustc --version; cargo --version; rustup --version | ||
- run: | ||
name: Calculate dependencies | ||
command: cargo generate-lockfile | ||
- restore_cache: | ||
name: restore project build artifacts | ||
keys: | ||
- v4-cargo-cache-{{ arch }}-{{ checksum "Cargo.lock" }} | ||
- run: | ||
name: Build all targets | ||
command: cargo build --all --all-targets | ||
command: cargo build --all --all-targets --all-features | ||
- save_cache: | ||
name: save project build artifacts | ||
paths: | ||
- /usr/local/cargo/registry | ||
- ~/.cargo/registry | ||
- target/debug/.fingerprint | ||
- target/debug/build | ||
- target/debug/deps | ||
key: v4-cargo-cache-{{ arch }}-{{ checksum "Cargo.lock" }} | ||
|
||
jobs: | ||
build: | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
test: | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
- run: | ||
name: Run all tests | ||
command: cargo test --all | ||
command: cargo test --all --all-features | ||
- run: | ||
name: Run slow tests | ||
command: cargo test -- --ignored | ||
lint: | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
- run: | ||
name: Format | ||
command: | | ||
rustup component add rustfmt | ||
cargo fmt --all -- --check | ||
- run: | ||
name: Clippy | ||
command: | | ||
rustup component add clippy | ||
cargo clippy --all-features -- -D warnings | ||
coverage: | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
- restore_cache: | ||
keys: | ||
- cargo-tarpaulin-0.8.6 | ||
- run: | ||
name: install cargo tarpaulin | ||
command: cargo install cargo-tarpaulin --version 0.8.6 || echo "cargo-tarpaulin already installed" | ||
environment: | ||
RUSTFLAGS: --cfg procmacro2_semver_exempt | ||
- save_cache: | ||
paths: | ||
- ~/.cargo/bin/cargo-tarpaulin | ||
key: cargo-tarpaulin-0.8.6 | ||
- run: | ||
name: Generate coverage report | ||
command: cargo tarpaulin --out Xml --all --all-features -t 600 | ||
environment: | ||
LZMA_API_STATIC: 1 | ||
- run: | ||
name: Export coverage to codecov | ||
command: bash <(curl -s https://codecov.io/bash) || echo "Failed to upload coverage" | ||
bench: | ||
# TODO: probably need to do something useful here (use critcmp?) before turning this on | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
- run: | ||
name: Run benchmarks | ||
command: | | ||
cargo bench | ||
fuzz: | ||
# TODO: need to figure out how to install nightly here and probably cache the cargo-fuzz binary | ||
executor: needletail | ||
steps: | ||
- checkout_and_setup | ||
- run: | ||
name: Run fuzz for 3 minutes each | ||
command: | | ||
cargo +nightly install cargo-fuzz | ||
cargo +nightly fuzz run parse_fasta -- -max_total_time=180 | ||
cargo +nightly fuzz run parse_fastq -- -max_total_time=180 | ||
workflows: | ||
version: 2 | ||
tests: | ||
ci-checks: | ||
jobs: | ||
- test | ||
- build | ||
- coverage: | ||
requires: | ||
- build | ||
- test: | ||
requires: | ||
- build | ||
- lint: | ||
requires: | ||
- build |
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
This file was deleted.
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
Oops, something went wrong.