-
-
Notifications
You must be signed in to change notification settings - Fork 3
/
unary-tests.txt
120 lines (82 loc) · 1.99 KB
/
unary-tests.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# Literals { "top": "UnaryTests" }
1,
true,
false,
"FOO",
-1220.12,
.12
==>
UnaryTests(PositiveUnaryTests(
PositiveUnaryTest(NumericLiteral),
PositiveUnaryTest(BooleanLiteral),
PositiveUnaryTest(BooleanLiteral),
PositiveUnaryTest(StringLiteral),
PositiveUnaryTest(NumericLiteral(...)),
PositiveUnaryTest(NumericLiteral)
))
# DateTimeLiteral { "top": "UnaryTests" }
date and time("2018-12-08T10:30:01"),
date and time(date("2017-01-01"),time("23:59:01")),
date("2017-01-01"),
time("23:59:01"),
duration("asddsa")
==>
UnaryTests(PositiveUnaryTests(
PositiveUnaryTest(DateTimeLiteral(...)),
PositiveUnaryTest(DateTimeLiteral(DateTimeConstructor(...),"(",PositionalParameters(
DateTimeLiteral(...),
DateTimeLiteral(...)
),")")),
PositiveUnaryTest(DateTimeLiteral(...)),
PositiveUnaryTest(DateTimeLiteral(...)),
PositiveUnaryTest(DateTimeLiteral(...))
))
# DateTimeLiteral / AtLiteral { "top": "UnaryTests" }
@"2018-12-08T10:30:01",
@"23:59:01"
==>
UnaryTests(PositiveUnaryTests(
PositiveUnaryTest(DateTimeLiteral(AtLiteral(StringLiteral))),
PositiveUnaryTest(DateTimeLiteral(...))
))
# ? Placeholder { "top": "UnaryTests" }
? > 10,
? * 10 in [1..5]
==>
UnaryTests(PositiveUnaryTests(
PositiveUnaryTest(Comparison("?",CompareOp,NumericLiteral)),
PositiveUnaryTest(Comparison(ArithmeticExpression("?",ArithOp,NumericLiteral),in,PositiveUnaryTest(...)))
))
# Interval { "top": "UnaryTests" }
[ a.b.c .. e f.g ]
==>
UnaryTests(
PositiveUnaryTests(
PositiveUnaryTest(
SimplePositiveUnaryTest(
Interval("[",
PathExpression(...),
PathExpression(...),
"]")
)
)
)
)
# Negation { "top": "UnaryTests" }
not(a)
==>
UnaryTests(not,"(",PositiveUnaryTests(...),")")
# Wildcard { "top": "UnaryTests" }
-
==>
UnaryTests(Wildcard(...))
# Backtick escaped variables (Camunda) { "top": "UnaryTests", "dialect": "camunda" }
`foo`
==>
UnaryTests(
PositiveUnaryTests(
PositiveUnaryTest(
VariableName(...)
)
)
)