Skip to content

Commit d4ca398

Browse files
committed
add tests
1 parent 449ab93 commit d4ca398

File tree

2 files changed

+27
-0
lines changed

2 files changed

+27
-0
lines changed

tree-sitter-dscexpression/corpus/invalid_expressions.txt

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,3 +124,17 @@ Invalid float argument
124124
(ERROR
125125
(functionName)
126126
(memberName)))))
127+
128+
=====
129+
Plus-sign number argument
130+
=====
131+
[myFunction(+1)]
132+
---
133+
134+
(statement
135+
(expression
136+
(function
137+
(functionName)
138+
(ERROR
139+
(UNEXPECTED '+')
140+
(memberName)))))

tree-sitter-dscexpression/corpus/valid_expressions.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,3 +127,16 @@ Quotes float input
127127
(functionName)
128128
(arguments
129129
(string)))))
130+
131+
=====
132+
Float input starting with decimal
133+
=====
134+
[myFunction(.1)]
135+
---
136+
137+
(statement
138+
(expression
139+
(function
140+
(functionName)
141+
(arguments
142+
(number)))))

0 commit comments

Comments
 (0)