Skip to content
This repository has been archived by the owner on May 4, 2024. It is now read-only.

[Feature Request] Unit tests need stronger abort code support #128

Open
tnowacki opened this issue May 12, 2022 · 0 comments
Open

[Feature Request] Unit tests need stronger abort code support #128

tnowacki opened this issue May 12, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@tnowacki
Copy link
Member

As highlighted in #127, abort_code annotation in unit tests is not super expressive. We should support

  • Location (The module that gave the abort)
  • More general major + sub status

For the location, suggested syntax:

#[test(abort_code = 0x42::M::2)]
// or
#[test(abort_code = 2, abort_location = 0x42::M)]

Note: annotation support is lacking for this right now

For status codes, suggested syntax:

#[test(status_code = "VECTOR_OPERATION_ERROR", sub_status = 1)]
@tnowacki tnowacki added the enhancement New feature or request label May 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant