Skip to content

Commit

Permalink
Merge pull request #317 from multiversx/type-expression-parsers-unittest
Browse files Browse the repository at this point in the history
Added an unit test
  • Loading branch information
popenta authored Aug 22, 2023
2 parents 5b5a69e + 6f35fb6 commit 123cf23
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions src/smartcontracts/typesystem/typeExpressionParser.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,30 @@ describe("test parser", () => {
}
]
});

type = parser.parse("variadic<multi<array32,u32,array64>>");
assert.deepEqual(type.toJSON(), {
"name": "variadic",
"typeParameters": [
{
"name": "multi",
"typeParameters": [
{
"name": "array32",
"typeParameters": []
},
{
"name": "u32",
"typeParameters": []
},
{
"name": "array64",
"typeParameters": []
}
]
}
]
});
});

it("should parse expression: tuples", () => {
Expand Down

0 comments on commit 123cf23

Please sign in to comment.