-
Notifications
You must be signed in to change notification settings - Fork 49
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
Need tests for Metadata Structure #31
Comments
@msporny I edited your initial comment to reflect the latest version of the spec. |
I'm wondering how we can test this statement:
How do we know property definitions on the test suite side? We just assume non-core properties to be in the spec registry? |
The issue was discussed in a meeting on 2021-03-30
View the transcript7.4. Need tests for Metadata StructureSee github issue did-test-suite#31. Shigeya Suzuki: I almost finished writing tests besides one issue, related to the DID registry, as I commented in the issue. Brent Zundel: Thank you for the overview
Brent Zundel: Special Topic call this Thursday |
@msporny We don't want to close this yet.. The test (potentially) referring to DID SPEC REGISTRY is not yet complete.. |
Ok, reopened. I think there is a good argument for that statement to be human testable only... unless you have a clear machine-testable way to test that statement? |
Let me quote the statement again here:
From the core spec point of view, the above statement is not testable within the core spec. This spec text needs to be placed in DID-SPEC-REGISTRIES, not within core spec. I honestly have no idea whether we can treat this statement as "human testable." From a different perspective: since the current test implementation runs the whole test against the transcript of interaction with multiple method implementations, it is desirable to test properties defined in DID-SPEC-REGISTRIES. In this case, we need a machine-readable -- at least partial -- DID-SPEC-REGISTRY. I think there are three options:
It is possible to create an optional configuration parameter that may hold machine-readable (possibly partial) DID-SPEC-REGISTRIES, which can be usable for the above option 3. (Note: due to schedule conflict, I can't attend the special topic call this week) |
Correct.
Yes, agreed.
It is human testable. A human can check to see if "All metadata property definitions registered in the DID Specification Registries [DID-SPEC-REGISTRIES] define the value type, including any additional formats or restrictions to that value (for example, a string formatted as a date or as a decimal integer)." I suggest we do the second option (if we don't have to go through another CR to do it), or just flag the statement as human testable and not something the WG intended to test. We have lots of these sorts of statements in the DID Methods section. |
Yes, I should have close this and open a new one early. thanks. |
7.3 Metadata Structure
The structure used to communicate this metadata MUST be a map of properties.
Each property name MUST be a string.
Each property value MUST be a string, map, list, ordered set, boolean, or null.
The values within any complex data structures such as maps and lists MUST be one of these data types as well.
All metadata property definitions registered in the DID Specification Registries [DID-SPEC-REGISTRIES] MUST define the value type, including any additional formats or restrictions to that value (for example, a string formatted as a date or as a decimal integer).
The entire metadata structure MUST be serializable according to the JSON serialization rules in the [INFRA] specification.
The text was updated successfully, but these errors were encountered: