diff --git a/.travis.yml b/.travis.yml index 6b75fd98e..d2bfdd0db 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,6 +8,8 @@ matrix: cache: apt: true directories: + - target/debug/deps + - target/debug/build - target/release/deps - target/release/build addons: @@ -30,8 +32,14 @@ script: after_success: | wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz && tar xzf master.tar.gz && mkdir kcov-master/build && cd kcov-master/build && cmake .. && make && make install DESTDIR=../tmp && cd ../.. && - ls target/release && - ./kcov-master/tmp/usr/local/bin/kcov --coveralls-id=${COVERALLS_TOKEN} --exclude-pattern=/.cargo --include-pattern=ethcore/src target/kcov target/release/deps/ethcore-* && + cargo test --no-run -p ethcore-util && + ./kcov-master/tmp/usr/local/bin/kcov --exclude-pattern /.cargo,/root/.multirust target/kcov target/debug/deps/ethcore_util-* && + cargo test --no-run -p ethash && + ./kcov-master/tmp/usr/local/bin/kcov --exclude-pattern /.cargo,/root/.multirust target/kcov target/debug/deps/ethash-* && + cargo test --no-run -p ethcore --no-default-features && + ./kcov-master/tmp/usr/local/bin/kcov --exclude-pattern /.cargo,/root/.multirust target/kcov target/debug/deps/ethcore-* && + cargo test --no-run && + ./kcov-master/tmp/usr/local/bin/kcov --coveralls-id=${COVERALLS_TOKEN} --exclude-pattern /.cargo,/root/.multirust target/kcov target/debug/parity-* [ $TRAVIS_BRANCH = master ] && [ $TRAVIS_PULL_REQUEST = false ] && [ $TRAVIS_RUST_VERSION = nightly ] && diff --git a/ethcore/Cargo.toml b/ethcore/Cargo.toml index 92236bd93..35fa5df81 100644 --- a/ethcore/Cargo.toml +++ b/ethcore/Cargo.toml @@ -25,6 +25,8 @@ crossbeam = "0.1.5" lazy_static = "0.1" [features] +default = ["json-tests"] jit = ["evmjit"] evm-debug = [] +json-tests = [] test-heavy = [] diff --git a/ethcore/src/tests/test_common.rs b/ethcore/src/tests/test_common.rs index 87e7b979e..fd88ae96a 100644 --- a/ethcore/src/tests/test_common.rs +++ b/ethcore/src/tests/test_common.rs @@ -12,6 +12,7 @@ macro_rules! declare_test { #[ignore] #[test] #[allow(non_snake_case)] + #[cfg(feature="json-tests")] fn $id() { test!($name); } @@ -20,6 +21,7 @@ macro_rules! declare_test { #[cfg(feature = "test-heavy")] #[test] #[allow(non_snake_case)] + #[cfg(feature="json-tests")] fn $id() { test!($name); } @@ -27,6 +29,7 @@ macro_rules! declare_test { ($id: ident, $name: expr) => { #[test] #[allow(non_snake_case)] + #[cfg(feature="json-tests")] fn $id() { test!($name); }