Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example test cases for common edge cases in state resolution #1989

Open
CobaltCause opened this issue Nov 6, 2024 · 0 comments
Open

Example test cases for common edge cases in state resolution #1989

CobaltCause opened this issue Nov 6, 2024 · 0 comments
Labels
clarification An area where the expected behaviour is understood, but the spec could do with being more explicit

Comments

@CobaltCause
Copy link

CobaltCause commented Nov 6, 2024

As a positive example, the section for Canonical JSON has an examples subsection which shows how to encode a few JSON objects into Canonical JSON.

I think a similar set of prescribed example test cases for state resolution would be very helpful for validating an implementation. I imagine each example would have a set of PDUs as input, and the output could be:

  • the resolved state
  • a list of edges in the auth chain graph of the resolved state
    • this would help ensure that the algorithm reaches the correct state by the correct path, rather than doing something wrong but still ending up with the right answer somehow
  • the set of rejected events, and ideally the reasons why these events were rejected
  • maybe other stuff I'm not thinking of

I acknowledge that because the data involved here would be rather large, it might be hard to actually fit this into the spec somewhere, and I don't have any suggestions for overcoming that.

Keywords: test vectors

@CobaltCause CobaltCause added the clarification An area where the expected behaviour is understood, but the spec could do with being more explicit label Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clarification An area where the expected behaviour is understood, but the spec could do with being more explicit
Projects
None yet
Development

No branches or pull requests

1 participant