tape
tape copied to clipboard
Support for complex (struct) arguments
Is your proposal related to a problem?
Currently the config file only allows for the arguments to be of the following types: uuid, randomString$length, randomNumberA_B. However chain codes can also take structs as the arguments instead for using just a list of variables. I have found that using structs instead of positionall arguments is a bit more reliable way to prevent errors when passing parameters.
Describe the solution you'd like
Allow for parameters to take the shape of a yaml object using the same random types to populate the fields
Describe alternatives you've considered
I currently am using hyperledger caliper as its workflows supports arbitrary parameters types
tape uses golang language, hence is there any go library which supports arbitrary parameters types? fuzz?
but how to define the structure in yaml and make golang auto generate the random value via fuzz? or we want the value in a specific range or ... some thing to make the test meaningful?
@Nova38 , could you please try with comments at https://github.com/hyperledger/fabric-chaincode-go/issues/101#issuecomment-2003731587 ?
@Nova38 , as tape support json format of input https://github.com/Hyperledger-TWGC/tape/blob/master/pkg/infra/trafficGenerator/proposal_test.go#L47 , please help a try and feedback.
Fantastic thank you! I will try it out this week
Fantastic thank you! I will try it out this week
hi @Nova38 , any feedback or result?