Skip to content

Conversation

murisi
Copy link
Contributor

@murisi murisi commented Oct 1, 2025

Based on the same code as #341 . This PR is an attempt to integrate generalized transaction generation with the property tests that induce transaction failure. The end goal being to generate a larger range of failing transactions and discover potential issues. Specifically, the following approach is taken:

  • Use Murisi/generalize tx generation #341 to generate a maximally general transaction that would actually successfully execute
  • Make exactly one mutation/modification to this transaction so that it will fail in a known way
  • Execute this mutated transaction and check that it fails in exactly that known way
  • In pseudo-code, the tests now look like mutationTestExecuteNonExistingRootFails(vm.transaction(_mockVerifier, txParams), mutParams);

Currently in main we only mutate a more limited set of transactions where actions all have the same number of compliance units (amongst other minor restrictions). This draft is only for checking/demonstrating whether this idea is workable and for testing the latest proposed changes to the protocol adapter. This PR would have to be rebased for actual use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant