test file directory

Signed-off-by: sapthasurendran <saptha.surendran@ibm.com>
This commit is contained in:
sapthasurendran 2022-07-01 12:20:43 +05:30
parent 8802bcb884
commit 02465a4386
2 changed files with 260 additions and 255 deletions

View file

@ -20,88 +20,88 @@ variables:
value: $(Build.Repository.LocalPath)/bin:/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/sbin value: $(Build.Repository.LocalPath)/bin:/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/sbin
- group: credentials - group: credentials
jobs: # jobs:
- job: REST_Sample # - job: REST_Sample
displayName: REST Server Sample # displayName: REST Server Sample
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/asset-transfer-basic/azure-pipelines-rest.yml # - template: templates/asset-transfer-basic/azure-pipelines-rest.yml
- job: CommercialPaper_Go # - job: CommercialPaper_Go
displayName: Commercial Paper (Go) # displayName: Commercial Paper (Go)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/commercial-paper/azure-pipelines-go.yml # - template: templates/commercial-paper/azure-pipelines-go.yml
- job: CommercialPaper_Java # - job: CommercialPaper_Java
displayName: Commercial Paper (Java) # displayName: Commercial Paper (Java)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/commercial-paper/azure-pipelines-java.yml # - template: templates/commercial-paper/azure-pipelines-java.yml
- job: CommercialPaper_JavaScript # - job: CommercialPaper_JavaScript
displayName: Commercial Paper (JavaScript) # displayName: Commercial Paper (JavaScript)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/commercial-paper/azure-pipelines-javascript.yml # - template: templates/commercial-paper/azure-pipelines-javascript.yml
- job: FabCar_Go # - job: FabCar_Go
displayName: FabCar (Go) # displayName: FabCar (Go)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/fabcar/azure-pipelines-go.yml # - template: templates/fabcar/azure-pipelines-go.yml
- job: FabCar_Java # - job: FabCar_Java
displayName: FabCar (Java) # displayName: FabCar (Java)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/fabcar/azure-pipelines-java.yml # - template: templates/fabcar/azure-pipelines-java.yml
- job: FabCar_JavaScript # - job: FabCar_JavaScript
displayName: FabCar (JavaScript) # displayName: FabCar (JavaScript)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/fabcar/azure-pipelines-javascript.yml # - template: templates/fabcar/azure-pipelines-javascript.yml
- job: Fabcar_TypeScript # - job: Fabcar_TypeScript
displayName: FabCar (TypeScript) # displayName: FabCar (TypeScript)
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- template: templates/fabcar/azure-pipelines-typescript.yml # - template: templates/fabcar/azure-pipelines-typescript.yml
- job: Lint # - job: Lint
displayName: Lint # displayName: Lint
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
steps: # steps:
- task: GoTool@0 # - task: GoTool@0
inputs: # inputs:
goBin: $(GO_BIN) # goBin: $(GO_BIN)
version: $(GO_VER) # version: $(GO_VER)
displayName: Install GoLang # displayName: Install GoLang
- task: NodeTool@0 # - task: NodeTool@0
inputs: # inputs:
versionSpec: $(NODE_VER) # versionSpec: $(NODE_VER)
displayName: Install Node.js # displayName: Install Node.js
- script: ./ci/scripts/shellcheck.sh # - script: ./ci/scripts/shellcheck.sh
displayName: Lint Shell Scripts # displayName: Lint Shell Scripts
- script: ./ci/scripts/lint.sh # - script: ./ci/scripts/lint.sh
displayName: Lint Code # displayName: Lint Code
- job: TestNetworkBasic - job: TestNetworkBasic
displayName: Test Network displayName: Test Network
@ -129,106 +129,106 @@ jobs:
workingDirectory: test-network workingDirectory: test-network
displayName: Run Test Network Basic Chaincode displayName: Run Test Network Basic Chaincode
- job: KubeTestNetworkBasic # - job: KubeTestNetworkBasic
displayName: Kube Test Network # displayName: Kube Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
CCaaS-Java: # CCaaS-Java:
CLIENT_LANGUAGE: typescript # CLIENT_LANGUAGE: typescript
CHAINCODE_LANGUAGE: java # CHAINCODE_LANGUAGE: java
CCaaS-Golang: # CCaaS-Golang:
CLIENT_LANGUAGE: typescript # CLIENT_LANGUAGE: typescript
CHAINCODE_LANGUAGE: external # CHAINCODE_LANGUAGE: external
K8s-Builder-Java: # K8s-Builder-Java:
CHAINCODE_NAME: basic # CHAINCODE_NAME: basic
CHAINCODE_LANGUAGE: java # CHAINCODE_LANGUAGE: java
CHAINCODE_BUILDER: k8s # CHAINCODE_BUILDER: k8s
steps: # steps:
- template: templates/install-k8s-deps.yml # - template: templates/install-k8s-deps.yml
- script: ../ci/scripts/run-k8s-test-network-basic.sh # - script: ../ci/scripts/run-k8s-test-network-basic.sh
workingDirectory: test-network-k8s # workingDirectory: test-network-k8s
displayName: Run Kubernetes Test Network Basic Asset Transfer # displayName: Run Kubernetes Test Network Basic Asset Transfer
- job: TestNetworkLedger # - job: TestNetworkLedger
displayName: Test Network # displayName: Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
Ledger-Go: # Ledger-Go:
CHAINCODE_NAME: ledger # CHAINCODE_NAME: ledger
CHAINCODE_LANGUAGE: go # CHAINCODE_LANGUAGE: go
Ledger-Javascript: # Ledger-Javascript:
CHAINCODE_NAME: ledger # CHAINCODE_NAME: ledger
CHAINCODE_LANGUAGE: javascript # CHAINCODE_LANGUAGE: javascript
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- script: ../ci/scripts/run-test-network-ledger.sh # - script: ../ci/scripts/run-test-network-ledger.sh
workingDirectory: test-network # workingDirectory: test-network
displayName: Run Test Network Ledger Chaincode # displayName: Run Test Network Ledger Chaincode
- job: TestNetworkPrivate # - job: TestNetworkPrivate
displayName: Test Network # displayName: Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
Private-Go: # Private-Go:
CHAINCODE_NAME: private # CHAINCODE_NAME: private
CHAINCODE_LANGUAGE: go # CHAINCODE_LANGUAGE: go
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- script: ../ci/scripts/run-test-network-private.sh # - script: ../ci/scripts/run-test-network-private.sh
workingDirectory: test-network # workingDirectory: test-network
displayName: Run Test Network Private Chaincode # displayName: Run Test Network Private Chaincode
- job: TestNetworkSBE # - job: TestNetworkSBE
displayName: Test Network # displayName: Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
SBE-Typescript: # SBE-Typescript:
CHAINCODE_NAME: sbe # CHAINCODE_NAME: sbe
CHAINCODE_LANGUAGE: typescript # CHAINCODE_LANGUAGE: typescript
SBE-Java: # SBE-Java:
CHAINCODE_NAME: sbe # CHAINCODE_NAME: sbe
CHAINCODE_LANGUAGE: java # CHAINCODE_LANGUAGE: java
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- script: ../ci/scripts/run-test-network-sbe.sh # - script: ../ci/scripts/run-test-network-sbe.sh
workingDirectory: test-network # workingDirectory: test-network
displayName: Run Test Network SBE Chaincode # displayName: Run Test Network SBE Chaincode
- job: TestNetworkSecured # - job: TestNetworkSecured
displayName: Test Network # displayName: Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
Secured-Go: # Secured-Go:
CHAINCODE_NAME: secured # CHAINCODE_NAME: secured
CHAINCODE_LANGUAGE: go # CHAINCODE_LANGUAGE: go
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- script: ../ci/scripts/run-test-network-secured.sh # - script: ../ci/scripts/run-test-network-secured.sh
workingDirectory: test-network # workingDirectory: test-network
displayName: Run Test Network Secured Chaincode # displayName: Run Test Network Secured Chaincode
- job: TestNetworkEvents # - job: TestNetworkEvents
displayName: Test Network # displayName: Test Network
pool: # pool:
vmImage: ubuntu-20.04 # vmImage: ubuntu-20.04
strategy: # strategy:
matrix: # matrix:
Events-Javascript: # Events-Javascript:
CHAINCODE_NAME: events # CHAINCODE_NAME: events
CHAINCODE_LANGUAGE: javascript # CHAINCODE_LANGUAGE: javascript
steps: # steps:
- template: templates/install-deps.yml # - template: templates/install-deps.yml
- script: ../ci/scripts/run-test-network-events.sh # - script: ../ci/scripts/run-test-network-events.sh
workingDirectory: test-network # workingDirectory: test-network
displayName: Run Test Network Events Chaincode # displayName: Run Test Network Events Chaincode

View file

@ -26,66 +26,66 @@ function stopNetwork() {
./network.sh down ./network.sh down
} }
# Run Go application # # Run Go application
createNetwork # createNetwork
print "Initializing Go application" # print "Initializing Go application"
pushd ../asset-transfer-basic/application-go # pushd ../asset-transfer-basic/application-go
print "Executing AssetTransfer.go" # print "Executing AssetTransfer.go"
go run . # go run .
popd # popd
stopNetwork # stopNetwork
# Run Java application # # Run Java application
createNetwork # createNetwork
print "Initializing Java application" # print "Initializing Java application"
pushd ../asset-transfer-basic/application-java # pushd ../asset-transfer-basic/application-java
print "Executing Gradle Run" # print "Executing Gradle Run"
gradle run # gradle run
popd # popd
stopNetwork # stopNetwork
# Run Java application using gateway # # Run Java application using gateway
createNetwork # createNetwork
print "Initializing Java application" # print "Initializing Java application"
pushd ../asset-transfer-basic/application-gateway-java # pushd ../asset-transfer-basic/application-gateway-java
print "Executing Gradle Run" # print "Executing Gradle Run"
./gradlew run # ./gradlew run
popd # popd
stopNetwork # stopNetwork
# Run Javascript application # # Run Javascript application
createNetwork # createNetwork
print "Initializing Javascript application" # print "Initializing Javascript application"
pushd ../asset-transfer-basic/application-javascript # pushd ../asset-transfer-basic/application-javascript
npm install # npm install
print "Executing app.js" # print "Executing app.js"
node app.js # node app.js
popd # popd
stopNetwork # stopNetwork
# Run typescript application # # Run typescript application
createNetwork # createNetwork
print "Initializing Typescript application" # print "Initializing Typescript application"
pushd ../asset-transfer-basic/application-typescript # pushd ../asset-transfer-basic/application-typescript
npm install # npm install
print "Building app.ts" # print "Building app.ts"
npm run build # npm run build
print "Running the output app" # print "Running the output app"
node dist/app.js # node dist/app.js
popd # popd
stopNetwork # stopNetwork
# Run gateway typescript application # # Run gateway typescript application
createNetwork # createNetwork
print "Initializing Typescript gateway application" # print "Initializing Typescript gateway application"
pushd ../asset-transfer-basic/application-gateway-typescript # pushd ../asset-transfer-basic/application-gateway-typescript
npm install # npm install
print "Building app.ts" # print "Building app.ts"
npm run build # npm run build
print "Running the output app" # print "Running the output app"
node dist/app.js # node dist/app.js
popd # popd
stopNetwork # stopNetwork
# Run typescript HSM application # Run typescript HSM application
createNetwork createNetwork
@ -107,6 +107,11 @@ echo 'Delete fabric-ca-client from samples bin'
rm ../bin/fabric-ca-client rm ../bin/fabric-ca-client
echo 'go install pkcs11 enabled fabric-ca-client' echo 'go install pkcs11 enabled fabric-ca-client'
go install -tags pkcs11 github.com/hyperledger/fabric-ca/cmd/fabric-ca-client@latest go install -tags pkcs11 github.com/hyperledger/fabric-ca/cmd/fabric-ca-client@latest
FILE=../bin/fabric-ca-client
if test -f "$FILE"; then
echo "$FILE exists."
fi
ls -la ../bin
createNetwork createNetwork
print "Initializing Typescript HSM gateway application" print "Initializing Typescript HSM gateway application"
pushd ../asset-transfer-basic/application-gateway-hsm/scripts/ pushd ../asset-transfer-basic/application-gateway-hsm/scripts/
@ -136,34 +141,34 @@ popd
popd popd
stopNetwork stopNetwork
# Run Go gateway application # # Run Go gateway application
createNetwork # createNetwork
print "Initializing Go gateway application" # print "Initializing Go gateway application"
pushd ../asset-transfer-basic/application-gateway-go # pushd ../asset-transfer-basic/application-gateway-go
print "Executing AssetTransfer.go" # print "Executing AssetTransfer.go"
go run . # go run .
popd # popd
stopNetwork # stopNetwork
# Run off-chain data TypeScript application # # Run off-chain data TypeScript application
createNetwork # createNetwork
print "Initializing Typescript off-chain data application" # print "Initializing Typescript off-chain data application"
pushd ../off_chain_data/application-typescript # pushd ../off_chain_data/application-typescript
rm -f checkpoint.json store.log # rm -f checkpoint.json store.log
npm install # npm install
print "Running the output app" # print "Running the output app"
SIMULATED_FAILURE_COUNT=1 npm start getAllAssets transact getAllAssets listen # SIMULATED_FAILURE_COUNT=1 npm start getAllAssets transact getAllAssets listen
SIMULATED_FAILURE_COUNT=1 npm start listen # SIMULATED_FAILURE_COUNT=1 npm start listen
popd # popd
stopNetwork # stopNetwork
# Run off-chain data Java application # # Run off-chain data Java application
createNetwork # createNetwork
print "Initializing Typescript off-chain data application" # print "Initializing Typescript off-chain data application"
pushd ../off_chain_data/application-java # pushd ../off_chain_data/application-java
rm -f app/checkpoint.json app/store.log # rm -f app/checkpoint.json app/store.log
print "Running the output app" # print "Running the output app"
SIMULATED_FAILURE_COUNT=1 ./gradlew run --quiet --args='getAllAssets transact getAllAssets listen' # SIMULATED_FAILURE_COUNT=1 ./gradlew run --quiet --args='getAllAssets transact getAllAssets listen'
SIMULATED_FAILURE_COUNT=1 ./gradlew run --quiet --args=listen # SIMULATED_FAILURE_COUNT=1 ./gradlew run --quiet --args=listen
popd # popd
stopNetwork # stopNetwork