github.com/darrenli6/fabric-sdk-example@v0.0.0-20220109053535-94b13b56df8c/test/feature/peer.feature (about) 1 # Copyright IBM Corp. 2017 All Rights Reserved. 2 # 3 # Licensed under the Apache License, Version 2.0 (the "License"); 4 # you may not use this file except in compliance with the License. 5 # You may obtain a copy of the License at 6 # 7 # http://www.apache.org/licenses/LICENSE-2.0 8 # 9 # Unless required by applicable law or agreed to in writing, software 10 # distributed under the License is distributed on an "AS IS" BASIS, 11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 # See the License for the specific language governing permissions and 13 # limitations under the License. 14 # 15 16 Feature: Peer Service 17 As a user I want to be able have channels and chaincodes to execute 18 19 #@doNotDecompose 20 @daily 21 Scenario Outline: FAB-3505: Test chaincode example02 deploy, invoke, and query 22 Given I have a bootstrapped fabric network of type <type> 23 And I wait "<waitTime>" seconds 24 When a user deploys chaincode at path "github.com/hyperledger/fabric/examples/chaincode/go/chaincode_example02" with ["init","a","1000","b","2000"] with name "mycc" 25 And I wait "5" seconds 26 Then the chaincode is deployed 27 When a user queries on the chaincode named "mycc" with args ["query","a"] 28 Then a user receives expected response of 1000 29 When a user invokes on the chaincode named "mycc" with args ["invoke","a","b","10"] 30 And a user queries on the chaincode named "mycc" with args ["query","a"] 31 Then a user receives expected response of 990 32 33 Given "peer0.org2.example.com" is taken down 34 When a user invokes on the chaincode named "mycc" with args ["invoke","a","b","10"] 35 And I wait "5" seconds 36 Given "peer0.org2.example.com" comes back up 37 And I wait "10" seconds 38 When a user queries on the chaincode named "mycc" with args ["query","a"] on "peer0.org2.example.com" 39 Then a user receives expected response of 980 from "peer0.org2.example.com" 40 Examples: 41 | type | waitTime | 42 | solo | 5 | 43 | kafka | 60 | 44 45 46 @daily 47 Scenario Outline: FAB-1440: Test basic chaincode deploy, invoke, query 48 Given I have a bootstrapped fabric network of type <type> 49 And I wait "<waitTime>" seconds 50 When a user deploys chaincode 51 Then the chaincode is deployed 52 When a user queries on the chaincode with args ["query","a"] 53 Then a user receives expected response of 100 54 Examples: 55 | type | waitTime | 56 | solo | 5 | 57 | kafka | 60 | 58 59 60 @daily 61 Scenario: FAB-3861: Basic Chaincode Execution (example02) 62 Given I have a bootstrapped fabric network 63 When a user deploys chaincode 64 Then the chaincode is deployed 65 66 67 @skip 68 Scenario: FAB-3865: Multiple Channels Per Peer 69 Given this test needs to be implemented 70 When a user gets a chance 71 Then the test will run 72 73 74 @skip 75 Scenario: FAB-3866: Multiple Chaincodes Per Peer 76 Given this test needs to be implemented 77 When a user gets a chance 78 Then the test will run