Skip to content

💡 [REQUEST] - Access instruction Return value in Fuzz Tests #391

@IaroslavMazur

Description

@IaroslavMazur

Summary

Problem

Currently, Trident's execute_transaction method doesn't allow accessing the Result<T> value returned by the executing instruction.

This limitation is especially troublesome in the context of View instructions, as they don't change the state of the blockchain - and, therefore, their Result<T> value is the only method there is to test the correctness of the respective instructions.

Current Workaround

None

Basic Example

let result = self.trident.execute_transaction(&mut my_tx, Some("MyTx"));
let returned_value = result.unwrap();

Drawbacks

None

Unresolved questions

No response

Implementation PR

No response

Reference Issues

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions