Skip to content

Commit

Permalink
Fixing schema tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Jakub Zajkowski committed Nov 26, 2024
1 parent 513950c commit 9ccecf1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 15 deletions.
6 changes: 3 additions & 3 deletions resources/test/rpc_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -5612,13 +5612,13 @@
"additionalProperties": false
},
{
"description": "A `Package`.",
"description": "A smart contract `Package`.",
"type": "object",
"required": [
"Package"
"SmartContract"
],
"properties": {
"Package": {
"SmartContract": {
"$ref": "#/components/schemas/Package"
}
},
Expand Down
15 changes: 4 additions & 11 deletions resources/test/speculative_rpc_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1652,13 +1652,13 @@
"additionalProperties": false
},
{
"description": "A `Package`.",
"description": "A smart contract `Package`.",
"type": "object",
"required": [
"Package"
"SmartContract"
],
"properties": {
"Package": {
"SmartContract": {
"$ref": "#/components/schemas/Package"
}
},
Expand Down Expand Up @@ -3787,14 +3787,7 @@
"properties": {
"hash_addr": {
"description": "The identity of the entity that produced the message.",
"type": "array",
"items": {
"type": "integer",
"format": "uint8",
"minimum": 0.0
},
"maxItems": 32,
"minItems": 32
"type": "string"
},
"message": {
"description": "The payload of the message.",
Expand Down
2 changes: 1 addition & 1 deletion rpc_sidecar/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ mod tests {
// schemars attribute too, indicating it is a hex-encoded string. See for example
// `TransactionInvocationTarget::Package::addr`.
/*
TODO -> reinstantiate this assertion once serialization ofhash_addr in Message structure in casper-types is fixed
TODO -> reinstantiate this assertion once serialization of DelegatorKind::Purse and UnbondKind::DelegatedPurse in casper-types is fixed
let regex = Regex::new(
r#"\s*"type":\s*"array",\s*"items":\s*\{\s*"type":\s*"integer",\s*"format":\s*"uint8",\s*"minimum":\s*0\.0\s*\},"#
).unwrap();
Expand Down

0 comments on commit 9ccecf1

Please sign in to comment.