Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: make test run faster #2747

Merged
merged 1 commit into from
Mar 14, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,12 @@ build-daemon-integration: modules plugin ## build PouchContainer daemon integrat
-cover -covermode=atomic -coverpkg ${COVERAGE_PACKAGES_LIST} \
-o bin/${DAEMON_INTEGRATION_BINARY_NAME}

build-integration-test: modules plugin ## build PouchContainer integration test-case binary
@echo $@
@mkdir -p bin
go test -c \
-o bin/${INTEGRATION_TESTCASE_BINARY_NAME} github.com/alibaba/pouch/test

modules: ## run modules to generate volume related code
@echo "build volume $@"
@./hack/module --clean
Expand Down Expand Up @@ -281,7 +287,7 @@ unit-test: modules plugin ## run go unit-test
done )

.PHONY: integration-test
integration-test: build-daemon-integration ## run daemon integration-test
integration-test: build-daemon-integration build-integration-test ## run daemon integration-test
@echo $@
@mkdir -p coverage
./hack/testing/run_daemon_integration.sh ${INTEGRATION_FLAGS}
Expand Down
2 changes: 1 addition & 1 deletion hack/testing/run_daemon_integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ integration::run_daemon_test_cases() {
local testcases
testcases=$(cat "${REPO_BASE}/test/testcase.list.${job_id}")
for one in ${testcases}; do
go test -check.v -check.f "${one}"
"${REPO_BASE}/bin/pouchd-integration-test" -test.v -check.v -check.f "${one}"
ret=$?
if [[ ${ret} -ne 0 ]]; then
code=${ret}
Expand Down