Fix blueprint generation for nested fields with Data

Having the data's schema be optional at the level of the 'Schema' did not allow to represent cases where there would be an opaque data at an arbitrary nesting. So I introduced a new variant 'Opaque' on 'Data' to fill that gap.
This commit is contained in:
KtorZ
2023-03-02 19:52:50 +01:00
committed by Lucas
parent a40f88b918
commit 6d098a4571
2 changed files with 55 additions and 53 deletions

View File

@@ -710,9 +710,18 @@ mod test {
"title": "test_module.spend",
"hash": "a3dbab684d90d19e6bab3a0b00a7290ff59fe637d14428859bf74376",
"datum": {
"title": "Data",
"description": "Any Plutus data.",
"schema": {},
"title": "Foo",
"schema": {
"anyOf": [{
"title": "Foo",
"index": 0,
"fields": [{
"title": "foo",
"description": "Any Plutus data.",
}],
"dataType": "constructor",
}]
},
},
"redeemer": {
"schema": {