You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently all the simulation tests are returning functions that implement the simtypes.Operation type:
// Operation runs a state machine transition, and ensures the transition// happened as expected. The operation could be running and testing a fuzzed// transaction, or doing the same for a message.//// For ease of debugging, an operation returns a descriptive message "action",// which details what this fuzzed state machine transition actually did.//// Operations can optionally provide a list of "FutureOperations" to run later// These will be ran at the beginning of the corresponding block.typeOperationfunc(r*rand.Rand, app*baseapp.BaseApp,
ctx sdk.Context, accounts []Account, chainIDstring) (
OperationMsgOperationMsg, futureOps []FutureOperation, errerror)
Even thought this type works properly the amount of parameters that requires is extremely large and causes the sim tests to look ugly and hard to maintain in the case some other data should be passed there instead. In order to solve this, I think we can encapsulate those values into a new Context type that can later be passed as the single parameter to the Operation type:
Currently all the simulation tests are returning functions that implement the
simtypes.Operation
type:Even thought this type works properly the amount of parameters that requires is extremely large and causes the sim tests to look ugly and hard to maintain in the case some other data should be passed there instead. In order to solve this, I think we can encapsulate those values into a new
Context
type that can later be passed as the single parameter to theOperation
type:This can be implemented directly inside the Cosmos SDK so that everyone can benefit from this
The text was updated successfully, but these errors were encountered: