Skip to content

Commit

Permalink
try to update CI sample to match with 2.2 (#184)
Browse files Browse the repository at this point in the history
  • Loading branch information
SamYuan1990 committed Jul 15, 2021
1 parent e87f926 commit f1425c7
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
5 changes: 4 additions & 1 deletion docs/FAQ.md
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
# FAQ 常见问题
# FAQ 常见问题

## Q:是否[初始化智能合约问题](https://github.com/Hyperledger-TWGC/tape/issues/181)
## A:Tape目前并不部署fabric网络,因此需要手工调用智能合约。以fabric-sample为例的参考[CI中的实现以及改动](https://github.com/Hyperledger-TWGC/tape/pull/184)
3 changes: 2 additions & 1 deletion test/config20org1andorg2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ orderer: *orderer1
channel: mychannel
chaincode: basic
args:
- GetAllAssets
- ReadAsset
- asset1
mspid: Org1MSP
private_key: /config/organizations/peerOrganizations/org1.example.com/users/User1@org1.example.com/msp/keystore/priv_sk
sign_cert: /config/organizations/peerOrganizations/org1.example.com/users/User1@org1.example.com/msp/signcerts/User1@org1.example.com-cert.pem
Expand Down
9 changes: 9 additions & 0 deletions test/integration-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ case $1 in
if [ $2 == "ORLogic" ]; then
CONFIG_FILE=/config/test/config20selectendorser.yaml
ARGS=(-ccep "OR('Org1.member','Org2.member')")
else
ARGS=(-cci initLedger)
fi

echo y | ./network.sh deployCC -ccn basic -ccp ../asset-transfer-basic/chaincode-go/ -ccl go "${ARGS[@]}"
Expand All @@ -56,6 +58,8 @@ case $1 in
if [ $2 == "ORLogic" ]; then
CONFIG_FILE=/config/test/config20selectendorser.yaml
ARGS=(-ccep "OR('Org1.member','Org2.member')")
else
ARGS=(-cci initLedger)
fi

echo y | ./network.sh deployCC -ccn basic -ccp ../asset-transfer-basic/chaincode-go/ -ccl go "${ARGS[@]}"
Expand All @@ -72,7 +76,10 @@ case $1 in
if [ $2 == "ORLogic" ]; then
CONFIG_FILE=/config/test/config20selectendorser.yaml
ARGS=(-ccep "OR('Org1.member','Org2.member')")
else
ARGS=(-cci initLedger)
fi


echo y | ./network.sh deployCC -ccn basic -ccp ../asset-transfer-basic/chaincode-go/ -ccl go "${ARGS[@]}"
;;
Expand All @@ -87,4 +94,6 @@ esac
cd "$DIR"
docker ps -a
docker network ls
## warm up for the init chaincode block
sleep 10
docker run -e TAPE_LOGLEVEL=debug --network $network -v $PWD:/config tape tape -c $CONFIG_FILE -n 500

0 comments on commit f1425c7

Please sign in to comment.