This repository was archived by the owner on Apr 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +12
-46
lines changed
Expand file tree Collapse file tree 4 files changed +12
-46
lines changed Original file line number Diff line number Diff line change @@ -210,10 +210,6 @@ license:
210210lint : populate
211211 @LINT_CHANGED_ONLY=true $(TEST_SCRIPTS_PATH ) /check_lint.sh
212212
213- .PHONY : lint-integration-tests
214- lint-integration-tests : populate
215- @LINT_CHANGED_ONLY=true $(TEST_SCRIPTS_PATH ) /check_lint_tests.sh
216-
217213.PHONY : lint-all
218214lint-all : populate
219215 @$(TEST_SCRIPTS_PATH ) /check_lint.sh
@@ -226,7 +222,7 @@ build-softhsm2-image:
226222 -f $(FIXTURE_SOFTHSM2_PATH ) /Dockerfile .
227223
228224.PHONY : unit-test
229- unit-test : license depend populate lint-integration-tests
225+ unit-test : license depend populate
230226 @TEST_CHANGED_ONLY=true TEST_WITH_LINTER=true FABRIC_SDKGO_CODELEVEL=$(FABRIC_CODELEVEL_UNITTEST_TAG ) FABRIC_SDKGO_CODELEVEL_VER=$(FABRIC_CODELEVEL_UNITTEST_VER ) $(TEST_SCRIPTS_PATH ) /unit.sh
231227ifeq ($(FABRIC_SDK_DEPRECATED_UNITTEST ) ,true)
232228 @GO_TAGS="$(GO_TAGS) deprecated" TEST_CHANGED_ONLY=true FABRIC_SDKGO_CODELEVEL=$(FABRIC_CODELEVEL_UNITTEST_TAG) FABRIC_SDKGO_CODELEVEL_VER=$(FABRIC_CODELEVEL_UNITTEST_VER) $(TEST_SCRIPTS_PATH)/unit.sh
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -75,6 +75,7 @@ if [ "${TEST_WITH_LINTER}" = true ]; then
7575 runLinter
7676fi
7777
78+ echo " Code level $FABRIC_SDKGO_CODELEVEL_TAG (Fabric ${FABRIC_SDKGO_CODELEVEL_VER} )"
7879echo " Running PKCS11 unit tests (libltdl and softhsm required)..."
7980
8081# detect softhsm
@@ -85,7 +86,6 @@ if [ "$SOFTHSM" == "" ]; then
8586 exit 1
8687fi
8788
88- echo " Testing with code level $FABRIC_SDKGO_CODELEVEL_TAG (Fabric ${FABRIC_SDKGO_CODELEVEL_VER} ) ..."
8989GO_TAGS=" $GO_TAGS $FABRIC_SDKGO_CODELEVEL_TAG "
9090
9191GO_LDFLAGS=" $GO_LDFLAGS -X github.com/hyperledger/fabric-sdk-go/test/metadata.ChannelConfigPath=test/fixtures/fabric/${FABRIC_SDKGO_CODELEVEL_VER} /channel -X github.com/hyperledger/fabric-sdk-go/test/metadata.CryptoConfigPath=test/fixtures/fabric/${FABRIC_CRYPTOCONFIG_VERSION} /crypto-config"
Original file line number Diff line number Diff line change @@ -34,8 +34,9 @@ echo "Running" $(basename "$0")
3434# Find all packages that should be tested.
3535declare -a PKG_SRC=(
3636 " ./pkg"
37+ " ./test"
3738)
38- declare PKG_EXCLUDE=" ( ${REPO} /pkg/core/cryptosuite/bccsp/multisuite| ${REPO} /pkg/core/cryptosuite/bccsp/pkcs11) "
39+ declare PKG_EXCLUDE=" "
3940findPackages
4041
4142# Reduce unit tests to changed packages.
@@ -73,8 +74,15 @@ if [ "${TEST_WITH_LINTER}" = true ]; then
7374 runLinter
7475fi
7576
77+ # filter out excluded tests
78+ PKGS=($( echo " ${PKGS[@]} " | tr ' ' ' \n' | \
79+ grep -v ^${REPO} /test | \
80+ grep -v ^${REPO} /pkg/core/cryptosuite/bccsp/multisuite | \
81+ grep -v ^${REPO} /pkg/core/cryptosuite/bccsp/pkcs11 | \
82+ tr ' ' ' \n' ) )
83+
84+ echo " Code level $FABRIC_SDKGO_CODELEVEL_TAG (Fabric ${FABRIC_SDKGO_CODELEVEL_VER} )"
7685echo " Running unit tests..."
77- echo " Testing with code level $FABRIC_SDKGO_CODELEVEL_TAG (Fabric ${FABRIC_SDKGO_CODELEVEL_VER} ) ..."
7886GO_TAGS=" $GO_TAGS $FABRIC_SDKGO_CODELEVEL_TAG "
7987
8088GO_LDFLAGS=" $GO_LDFLAGS -X github.com/hyperledger/fabric-sdk-go/test/metadata.ChannelConfigPath=test/fixtures/fabric/${FABRIC_SDKGO_CODELEVEL_VER} /channel -X github.com/hyperledger/fabric-sdk-go/test/metadata.CryptoConfigPath=test/fixtures/fabric/${FABRIC_CRYPTOCONFIG_VERSION} /crypto-config"
You can’t perform that action at this time.
0 commit comments