Skip to content

Commit a3f159e

Browse files
committed
[FAB-4099] Skip directories in unit tests search
Some directories contain code for unit-tests support or samples which should be excluded from unit-test search. Change-Id: Ia4ee2e70a899af9583cd22a104247bde4d1bcd91 Signed-off-by: Binh Q. Nguyen <[email protected]>
1 parent 5759ee4 commit a3f159e

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

unit-test/run.sh

+10-5
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,21 @@ echo -n "Obtaining list of tests to run for the following packages: ${TEST_PKGS}
1111
PKGS=`go list ${TEST_PKGS} 2> /dev/null | \
1212
grep -v /vendor/ | \
1313
grep -v /build/ | \
14+
grep -v /bccsp/mocks | \
1415
grep -v /bddtests | \
1516
grep -v /orderer/mocks | \
17+
grep -v /orderer/sample_clients | \
1618
grep -v /common/mocks | \
19+
grep -v /common/ledger/testutil | \
1720
grep -v /core/mocks | \
21+
grep -v /core/testutil | \
22+
grep -v /core/ledger/testutil | \
23+
grep -v /core/ledger/kvledger/example | \
24+
grep -v /core/ledger/kvledger/marble_example | \
25+
grep -v /core/deliverservice/mocks | \
26+
grep -v /core/scc/samplesyscc | \
1827
grep -v /test | \
19-
grep -v /examples/chaincode/chaintool/ | \
20-
grep -v /examples/chaincode/go/asset_management | \
21-
grep -v /examples/chaincode/go/utxo | \
22-
grep -v /examples/chaincode/go/rbac_tcerts_no_attrs`
28+
grep -v /examples`
2329

2430
if [ x$ARCH == xppc64le -o x$ARCH == xs390x ]
2531
then
@@ -31,4 +37,3 @@ echo "DONE!"
3137

3238
echo "Running tests..."
3339
gocov test -ldflags "$GO_LDFLAGS" $PKGS -p 1 -timeout=20m | gocov-xml > report.xml
34-

0 commit comments

Comments
 (0)