Macro sewup_derive::ewasm_err_output[][src]

ewasm_err_output!() { /* proc-macro */ }
Expand description

helps you to get the binary result of the thiserror,

such that you can assert your handler with error. for example:

#[ewasm_test]
mod tests {
   use super::*;

   #[ewasm_test]
   fn test_execute_basic_operations() {
       let mut simple_struct = SimpleStruct::default();

       ewasm_assert_eq!(
           check_input_object(simple_struct),
           ewasm_err_output!(Error::NotTrustedInput)
       );
   }
}