From f1190e3e2aef70045eb942c76a1fd58a6ed90fdf Mon Sep 17 00:00:00 2001 From: ian Date: Mon, 8 Apr 2019 19:39:51 +0800 Subject: [PATCH] chore: add make task to run integration test --- Makefile | 9 +++++++++ devtools/ci/script.sh | 6 ++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 5fcb8dcf8a..76faf03327 100644 --- a/Makefile +++ b/Makefile @@ -5,6 +5,14 @@ VERBOSE := $(if ${CI},--verbose,) test: cargo test ${VERBOSE} --all -- --nocapture +integration: + cargo build ${VERBOSE} + cd test && cargo run ../target/debug/ckb + +integration-release: + cargo build ${VERBOSE} --release + cd test && cargo run --release -- ../target/debug/ckb + doc: cargo doc --all --no-deps @@ -71,3 +79,4 @@ gen-clean: .PHONY: build prod prod-test docker gen gen-clean .PHONY: fmt test clippy doc doc-deps check stats .PHONY: ci info security-audit +.PHONY: integration integration-release diff --git a/devtools/ci/script.sh b/devtools/ci/script.sh index ea731302d2..1e42202152 100755 --- a/devtools/ci/script.sh +++ b/devtools/ci/script.sh @@ -19,10 +19,8 @@ fi git diff --exit-code Cargo.lock if [ "$TRAVIS_BRANCH" = master -o "$TRAVIS_BRANCH" = staging -o "$TRAVIS_BRANCH" = trying ]; then - cargo build - cd test && cargo run ../target/debug/ckb + make integration # Switch to release mode when the running time is much longer than the build time. - # cargo build --release - # cargo run --release -p ckb-test target/release/ckb + # make integration-release fi