@litert/typeguard 1.3.0-dev.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGES.md +7 -1
- package/lib/BuiltInTypeCompiler.d.ts +1 -1
- package/lib/BuiltInTypeCompiler.js +4 -4
- package/lib/BuiltInTypeCompiler.js.map +1 -1
- package/lib/BuiltInTypes.d.ts +1 -1
- package/lib/BuiltInTypes.js +1 -1
- package/lib/Common.d.ts +6 -5
- package/lib/Common.d.ts.map +1 -1
- package/lib/Common.js +1 -1
- package/lib/Compiler.d.ts +1 -1
- package/lib/Compiler.d.ts.map +1 -1
- package/lib/Compiler.js +57 -35
- package/lib/Compiler.js.map +1 -1
- package/lib/Context.d.ts +2 -2
- package/lib/Context.d.ts.map +1 -1
- package/lib/Context.js +2 -2
- package/lib/Context.js.map +1 -1
- package/lib/FilterCompiler.d.ts +3 -3
- package/lib/FilterCompiler.d.ts.map +1 -1
- package/lib/FilterCompiler.js +4 -4
- package/lib/FilterCompiler.js.map +1 -1
- package/lib/InlineCompiler.d.ts +2 -2
- package/lib/InlineCompiler.d.ts.map +1 -1
- package/lib/InlineCompiler.js +5 -7
- package/lib/InlineCompiler.js.map +1 -1
- package/lib/Internal.d.ts +9 -4
- package/lib/Internal.d.ts.map +1 -1
- package/lib/Internal.js +45 -4
- package/lib/Internal.js.map +1 -1
- package/lib/Modifiers.d.ts +2 -1
- package/lib/Modifiers.d.ts.map +1 -1
- package/lib/Modifiers.js +3 -2
- package/lib/Modifiers.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/langs/JavaScript.d.ts +1 -1
- package/lib/langs/JavaScript.js +2 -2
- package/package.json +11 -13
- package/src/examples/quick-start.ts +5 -1
- package/src/lib/BuiltInTypeCompiler.ts +4 -4
- package/src/lib/BuiltInTypes.ts +1 -1
- package/src/lib/Common.ts +5 -4
- package/src/lib/Compiler.ts +66 -39
- package/src/lib/Context.ts +2 -2
- package/src/lib/FilterCompiler.ts +3 -3
- package/src/lib/InlineCompiler.ts +6 -9
- package/src/lib/Internal.ts +73 -4
- package/src/lib/Modifiers.ts +3 -1
- package/src/lib/index.ts +1 -1
- package/src/lib/langs/JavaScript.ts +2 -2
- package/src/test/00-all.ts +1 -1
- package/src/test/01-elemental-types.ts +580 -580
- package/src/test/02-array-and-list.ts +43 -43
- package/src/test/03-tuple.ts +61 -61
- package/src/test/04-from-string.ts +501 -501
- package/src/test/05-string-asserts.ts +203 -203
- package/src/test/06-structure.ts +71 -71
- package/src/test/07-modifiers.ts +297 -48
- package/src/test/08-map-and-dict.ts +11 -11
- package/src/test/09-exceptions.ts +11 -11
- package/src/test/abstracts.ts +57 -29
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright
|
|
2
|
+
* Copyright 2023 Angus Fenying <fenying@litert.org>
|
|
3
3
|
*
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
5
|
* you may not use this file except in compliance with the License.
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
-
import { createTestDefinition,
|
|
17
|
+
import { createTestDefinition, defaultItems, ITestSuite } from './abstracts';
|
|
18
18
|
|
|
19
19
|
const testItems: ITestSuite = {
|
|
20
20
|
|
|
@@ -25,16 +25,16 @@ const testItems: ITestSuite = {
|
|
|
25
25
|
'rule': '==aasdsadsada',
|
|
26
26
|
'items': [
|
|
27
27
|
{
|
|
28
|
-
'
|
|
29
|
-
'
|
|
28
|
+
'title': 'string \'aasdsadsada\'',
|
|
29
|
+
'value': 'aasdsadsada',
|
|
30
30
|
'expect': true
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
|
-
'
|
|
34
|
-
'
|
|
33
|
+
'title': 'string \'AASDSADSADA\'',
|
|
34
|
+
'value': 'AASDSADSADA',
|
|
35
35
|
'expect': false
|
|
36
36
|
},
|
|
37
|
-
...
|
|
37
|
+
...defaultItems({})
|
|
38
38
|
]
|
|
39
39
|
},
|
|
40
40
|
{
|
|
@@ -42,16 +42,16 @@ const testItems: ITestSuite = {
|
|
|
42
42
|
'rule': '=aasdsadsada',
|
|
43
43
|
'items': [
|
|
44
44
|
{
|
|
45
|
-
'
|
|
46
|
-
'
|
|
45
|
+
'title': 'string \'aasdsadsada\'',
|
|
46
|
+
'value': 'aasdsadsada',
|
|
47
47
|
'expect': true
|
|
48
48
|
},
|
|
49
49
|
{
|
|
50
|
-
'
|
|
51
|
-
'
|
|
50
|
+
'title': 'string \'AASDSADSADA\'',
|
|
51
|
+
'value': 'AASDSADSADA',
|
|
52
52
|
'expect': false
|
|
53
53
|
},
|
|
54
|
-
...
|
|
54
|
+
...defaultItems({})
|
|
55
55
|
]
|
|
56
56
|
},
|
|
57
57
|
{
|
|
@@ -59,16 +59,16 @@ const testItems: ITestSuite = {
|
|
|
59
59
|
'rule': ':equal:aasdsadsada',
|
|
60
60
|
'items': [
|
|
61
61
|
{
|
|
62
|
-
'
|
|
63
|
-
'
|
|
62
|
+
'title': 'string \'aasdsadsada\'',
|
|
63
|
+
'value': 'aasdsadsada',
|
|
64
64
|
'expect': true
|
|
65
65
|
},
|
|
66
66
|
{
|
|
67
|
-
'
|
|
68
|
-
'
|
|
67
|
+
'title': 'string \'AASDSADSADA\'',
|
|
68
|
+
'value': 'AASDSADSADA',
|
|
69
69
|
'expect': false
|
|
70
70
|
},
|
|
71
|
-
...
|
|
71
|
+
...defaultItems({})
|
|
72
72
|
]
|
|
73
73
|
},
|
|
74
74
|
{
|
|
@@ -76,16 +76,16 @@ const testItems: ITestSuite = {
|
|
|
76
76
|
'rule': ':equal-i:aasdsadsada',
|
|
77
77
|
'items': [
|
|
78
78
|
{
|
|
79
|
-
'
|
|
80
|
-
'
|
|
79
|
+
'title': 'string \'aasdsadsada\'',
|
|
80
|
+
'value': 'aasdsadsada',
|
|
81
81
|
'expect': true
|
|
82
82
|
},
|
|
83
83
|
{
|
|
84
|
-
'
|
|
85
|
-
'
|
|
84
|
+
'title': 'string \'AASDSADSADA\'',
|
|
85
|
+
'value': 'AASDSADSADA',
|
|
86
86
|
'expect': true
|
|
87
87
|
},
|
|
88
|
-
...
|
|
88
|
+
...defaultItems({})
|
|
89
89
|
]
|
|
90
90
|
},
|
|
91
91
|
{
|
|
@@ -93,16 +93,16 @@ const testItems: ITestSuite = {
|
|
|
93
93
|
'rule': '%=aasdsadsada',
|
|
94
94
|
'items': [
|
|
95
95
|
{
|
|
96
|
-
'
|
|
97
|
-
'
|
|
96
|
+
'title': 'string \'aasdsadsada\'',
|
|
97
|
+
'value': 'aasdsadsada',
|
|
98
98
|
'expect': true
|
|
99
99
|
},
|
|
100
100
|
{
|
|
101
|
-
'
|
|
102
|
-
'
|
|
101
|
+
'title': 'string \'AASDSADSADA\'',
|
|
102
|
+
'value': 'AASDSADSADA',
|
|
103
103
|
'expect': true
|
|
104
104
|
},
|
|
105
|
-
...
|
|
105
|
+
...defaultItems({})
|
|
106
106
|
]
|
|
107
107
|
},
|
|
108
108
|
{
|
|
@@ -110,16 +110,16 @@ const testItems: ITestSuite = {
|
|
|
110
110
|
'rule': '!=aasdsadsada',
|
|
111
111
|
'items': [
|
|
112
112
|
{
|
|
113
|
-
'
|
|
114
|
-
'
|
|
113
|
+
'title': 'string \'aasdsadsada\'',
|
|
114
|
+
'value': 'aasdsadsada',
|
|
115
115
|
'expect': false
|
|
116
116
|
},
|
|
117
117
|
{
|
|
118
|
-
'
|
|
119
|
-
'
|
|
118
|
+
'title': 'string \'AASDSADSADA\'',
|
|
119
|
+
'value': 'AASDSADSADA',
|
|
120
120
|
'expect': true
|
|
121
121
|
},
|
|
122
|
-
...
|
|
122
|
+
...defaultItems({
|
|
123
123
|
'string \'hello\'': true,
|
|
124
124
|
'empty string': true
|
|
125
125
|
})
|
|
@@ -130,16 +130,16 @@ const testItems: ITestSuite = {
|
|
|
130
130
|
'rule': ':not-equal:aasdsadsada',
|
|
131
131
|
'items': [
|
|
132
132
|
{
|
|
133
|
-
'
|
|
134
|
-
'
|
|
133
|
+
'title': 'string \'aasdsadsada\'',
|
|
134
|
+
'value': 'aasdsadsada',
|
|
135
135
|
'expect': false
|
|
136
136
|
},
|
|
137
137
|
{
|
|
138
|
-
'
|
|
139
|
-
'
|
|
138
|
+
'title': 'string \'AASDSADSADA\'',
|
|
139
|
+
'value': 'AASDSADSADA',
|
|
140
140
|
'expect': true
|
|
141
141
|
},
|
|
142
|
-
...
|
|
142
|
+
...defaultItems({
|
|
143
143
|
'string \'hello\'': true,
|
|
144
144
|
'empty string': true
|
|
145
145
|
})
|
|
@@ -150,16 +150,16 @@ const testItems: ITestSuite = {
|
|
|
150
150
|
'rule': ':not-equal-i:aasdsadsada',
|
|
151
151
|
'items': [
|
|
152
152
|
{
|
|
153
|
-
'
|
|
154
|
-
'
|
|
153
|
+
'title': 'string \'aasdsadsada\'',
|
|
154
|
+
'value': 'aasdsadsada',
|
|
155
155
|
'expect': false
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
|
-
'
|
|
159
|
-
'
|
|
158
|
+
'title': 'string \'AASDSADSADA\'',
|
|
159
|
+
'value': 'AASDSADSADA',
|
|
160
160
|
'expect': false
|
|
161
161
|
},
|
|
162
|
-
...
|
|
162
|
+
...defaultItems({
|
|
163
163
|
'string \'hello\'': true,
|
|
164
164
|
'empty string': true
|
|
165
165
|
})
|
|
@@ -170,16 +170,16 @@ const testItems: ITestSuite = {
|
|
|
170
170
|
'rule': '%!aasdsadsada',
|
|
171
171
|
'items': [
|
|
172
172
|
{
|
|
173
|
-
'
|
|
174
|
-
'
|
|
173
|
+
'title': 'string \'aasdsadsada\'',
|
|
174
|
+
'value': 'aasdsadsada',
|
|
175
175
|
'expect': false
|
|
176
176
|
},
|
|
177
177
|
{
|
|
178
|
-
'
|
|
179
|
-
'
|
|
178
|
+
'title': 'string \'AASDSADSADA\'',
|
|
179
|
+
'value': 'AASDSADSADA',
|
|
180
180
|
'expect': false
|
|
181
181
|
},
|
|
182
|
-
...
|
|
182
|
+
...defaultItems({
|
|
183
183
|
'string \'hello\'': true,
|
|
184
184
|
'empty string': true
|
|
185
185
|
})
|
|
@@ -190,16 +190,16 @@ const testItems: ITestSuite = {
|
|
|
190
190
|
'rule': '^=hello',
|
|
191
191
|
'items': [
|
|
192
192
|
{
|
|
193
|
-
'
|
|
194
|
-
'
|
|
193
|
+
'title': 'string \'hello world\'',
|
|
194
|
+
'value': 'hello world',
|
|
195
195
|
'expect': true
|
|
196
196
|
},
|
|
197
197
|
{
|
|
198
|
-
'
|
|
199
|
-
'
|
|
198
|
+
'title': 'string \'hello world\'',
|
|
199
|
+
'value': 'Hello world',
|
|
200
200
|
'expect': false
|
|
201
201
|
},
|
|
202
|
-
...
|
|
202
|
+
...defaultItems({
|
|
203
203
|
'string \'hello\'': true,
|
|
204
204
|
'empty string': false
|
|
205
205
|
})
|
|
@@ -210,16 +210,16 @@ const testItems: ITestSuite = {
|
|
|
210
210
|
'rule': ':start-with:hello',
|
|
211
211
|
'items': [
|
|
212
212
|
{
|
|
213
|
-
'
|
|
214
|
-
'
|
|
213
|
+
'title': 'string \'hello world\'',
|
|
214
|
+
'value': 'hello world',
|
|
215
215
|
'expect': true
|
|
216
216
|
},
|
|
217
217
|
{
|
|
218
|
-
'
|
|
219
|
-
'
|
|
218
|
+
'title': 'string \'hello world\'',
|
|
219
|
+
'value': 'Hello world',
|
|
220
220
|
'expect': false
|
|
221
221
|
},
|
|
222
|
-
...
|
|
222
|
+
...defaultItems({
|
|
223
223
|
'string \'hello\'': true,
|
|
224
224
|
'empty string': false
|
|
225
225
|
})
|
|
@@ -230,16 +230,16 @@ const testItems: ITestSuite = {
|
|
|
230
230
|
'rule': ':start-with-i:hello',
|
|
231
231
|
'items': [
|
|
232
232
|
{
|
|
233
|
-
'
|
|
234
|
-
'
|
|
233
|
+
'title': 'string \'hello world\'',
|
|
234
|
+
'value': 'hello world',
|
|
235
235
|
'expect': true
|
|
236
236
|
},
|
|
237
237
|
{
|
|
238
|
-
'
|
|
239
|
-
'
|
|
238
|
+
'title': 'string \'hello world\'',
|
|
239
|
+
'value': 'Hello world',
|
|
240
240
|
'expect': true
|
|
241
241
|
},
|
|
242
|
-
...
|
|
242
|
+
...defaultItems({
|
|
243
243
|
'string \'hello\'': true,
|
|
244
244
|
'empty string': false
|
|
245
245
|
})
|
|
@@ -250,16 +250,16 @@ const testItems: ITestSuite = {
|
|
|
250
250
|
'rule': '^!hello',
|
|
251
251
|
'items': [
|
|
252
252
|
{
|
|
253
|
-
'
|
|
254
|
-
'
|
|
253
|
+
'title': 'string \'hello world\'',
|
|
254
|
+
'value': 'hello world',
|
|
255
255
|
'expect': false
|
|
256
256
|
},
|
|
257
257
|
{
|
|
258
|
-
'
|
|
259
|
-
'
|
|
258
|
+
'title': 'string \'hello world\'',
|
|
259
|
+
'value': 'Hello world',
|
|
260
260
|
'expect': true
|
|
261
261
|
},
|
|
262
|
-
...
|
|
262
|
+
...defaultItems({
|
|
263
263
|
'string \'hello\'': false,
|
|
264
264
|
'empty string': true
|
|
265
265
|
})
|
|
@@ -270,16 +270,16 @@ const testItems: ITestSuite = {
|
|
|
270
270
|
'rule': ':not-start-with:hello',
|
|
271
271
|
'items': [
|
|
272
272
|
{
|
|
273
|
-
'
|
|
274
|
-
'
|
|
273
|
+
'title': 'string \'hello world\'',
|
|
274
|
+
'value': 'hello world',
|
|
275
275
|
'expect': false
|
|
276
276
|
},
|
|
277
277
|
{
|
|
278
|
-
'
|
|
279
|
-
'
|
|
278
|
+
'title': 'string \'hello world\'',
|
|
279
|
+
'value': 'Hello world',
|
|
280
280
|
'expect': true
|
|
281
281
|
},
|
|
282
|
-
...
|
|
282
|
+
...defaultItems({
|
|
283
283
|
'string \'hello\'': false,
|
|
284
284
|
'empty string': true
|
|
285
285
|
})
|
|
@@ -290,16 +290,16 @@ const testItems: ITestSuite = {
|
|
|
290
290
|
'rule': ':not-start-with-i:hello',
|
|
291
291
|
'items': [
|
|
292
292
|
{
|
|
293
|
-
'
|
|
294
|
-
'
|
|
293
|
+
'title': 'string \'hello world\'',
|
|
294
|
+
'value': 'hello world',
|
|
295
295
|
'expect': false
|
|
296
296
|
},
|
|
297
297
|
{
|
|
298
|
-
'
|
|
299
|
-
'
|
|
298
|
+
'title': 'string \'hello world\'',
|
|
299
|
+
'value': 'Hello world',
|
|
300
300
|
'expect': false
|
|
301
301
|
},
|
|
302
|
-
...
|
|
302
|
+
...defaultItems({
|
|
303
303
|
'string \'hello\'': false,
|
|
304
304
|
'empty string': true
|
|
305
305
|
})
|
|
@@ -310,16 +310,16 @@ const testItems: ITestSuite = {
|
|
|
310
310
|
'rule': '$=world',
|
|
311
311
|
'items': [
|
|
312
312
|
{
|
|
313
|
-
'
|
|
314
|
-
'
|
|
313
|
+
'title': 'string \'hello world\'',
|
|
314
|
+
'value': 'hello world',
|
|
315
315
|
'expect': true
|
|
316
316
|
},
|
|
317
317
|
{
|
|
318
|
-
'
|
|
319
|
-
'
|
|
318
|
+
'title': 'string \'hello world\'',
|
|
319
|
+
'value': 'Hello World',
|
|
320
320
|
'expect': false
|
|
321
321
|
},
|
|
322
|
-
...
|
|
322
|
+
...defaultItems({
|
|
323
323
|
'string \'hello\'': false,
|
|
324
324
|
'empty string': false
|
|
325
325
|
})
|
|
@@ -330,16 +330,16 @@ const testItems: ITestSuite = {
|
|
|
330
330
|
'rule': ':end-with:world',
|
|
331
331
|
'items': [
|
|
332
332
|
{
|
|
333
|
-
'
|
|
334
|
-
'
|
|
333
|
+
'title': 'string \'hello world\'',
|
|
334
|
+
'value': 'hello world',
|
|
335
335
|
'expect': true
|
|
336
336
|
},
|
|
337
337
|
{
|
|
338
|
-
'
|
|
339
|
-
'
|
|
338
|
+
'title': 'string \'hello world\'',
|
|
339
|
+
'value': 'Hello World',
|
|
340
340
|
'expect': false
|
|
341
341
|
},
|
|
342
|
-
...
|
|
342
|
+
...defaultItems({
|
|
343
343
|
'string \'hello\'': false,
|
|
344
344
|
'empty string': false
|
|
345
345
|
})
|
|
@@ -350,16 +350,16 @@ const testItems: ITestSuite = {
|
|
|
350
350
|
'rule': ':end-with-i:world',
|
|
351
351
|
'items': [
|
|
352
352
|
{
|
|
353
|
-
'
|
|
354
|
-
'
|
|
353
|
+
'title': 'string \'hello world\'',
|
|
354
|
+
'value': 'hello world',
|
|
355
355
|
'expect': true
|
|
356
356
|
},
|
|
357
357
|
{
|
|
358
|
-
'
|
|
359
|
-
'
|
|
358
|
+
'title': 'string \'hello world\'',
|
|
359
|
+
'value': 'Hello World',
|
|
360
360
|
'expect': true
|
|
361
361
|
},
|
|
362
|
-
...
|
|
362
|
+
...defaultItems({
|
|
363
363
|
'string \'hello\'': false,
|
|
364
364
|
'empty string': false
|
|
365
365
|
})
|
|
@@ -370,16 +370,16 @@ const testItems: ITestSuite = {
|
|
|
370
370
|
'rule': '$!world',
|
|
371
371
|
'items': [
|
|
372
372
|
{
|
|
373
|
-
'
|
|
374
|
-
'
|
|
373
|
+
'title': 'string \'hello world\'',
|
|
374
|
+
'value': 'hello world',
|
|
375
375
|
'expect': false
|
|
376
376
|
},
|
|
377
377
|
{
|
|
378
|
-
'
|
|
379
|
-
'
|
|
378
|
+
'title': 'string \'hello world\'',
|
|
379
|
+
'value': 'Hello World',
|
|
380
380
|
'expect': true
|
|
381
381
|
},
|
|
382
|
-
...
|
|
382
|
+
...defaultItems({
|
|
383
383
|
'string \'hello\'': true,
|
|
384
384
|
'empty string': true
|
|
385
385
|
})
|
|
@@ -390,16 +390,16 @@ const testItems: ITestSuite = {
|
|
|
390
390
|
'rule': ':not-end-with:world',
|
|
391
391
|
'items': [
|
|
392
392
|
{
|
|
393
|
-
'
|
|
394
|
-
'
|
|
393
|
+
'title': 'string \'hello world\'',
|
|
394
|
+
'value': 'hello world',
|
|
395
395
|
'expect': false
|
|
396
396
|
},
|
|
397
397
|
{
|
|
398
|
-
'
|
|
399
|
-
'
|
|
398
|
+
'title': 'string \'hello world\'',
|
|
399
|
+
'value': 'Hello World',
|
|
400
400
|
'expect': true
|
|
401
401
|
},
|
|
402
|
-
...
|
|
402
|
+
...defaultItems({
|
|
403
403
|
'string \'hello\'': true,
|
|
404
404
|
'empty string': true
|
|
405
405
|
})
|
|
@@ -410,16 +410,16 @@ const testItems: ITestSuite = {
|
|
|
410
410
|
'rule': ':not-end-with-i:world',
|
|
411
411
|
'items': [
|
|
412
412
|
{
|
|
413
|
-
'
|
|
414
|
-
'
|
|
413
|
+
'title': 'string \'hello world\'',
|
|
414
|
+
'value': 'hello World',
|
|
415
415
|
'expect': false
|
|
416
416
|
},
|
|
417
417
|
{
|
|
418
|
-
'
|
|
419
|
-
'
|
|
418
|
+
'title': 'string \'hello world\'',
|
|
419
|
+
'value': 'Hello world',
|
|
420
420
|
'expect': false
|
|
421
421
|
},
|
|
422
|
-
...
|
|
422
|
+
...defaultItems({
|
|
423
423
|
'string \'hello\'': true,
|
|
424
424
|
'empty string': true
|
|
425
425
|
})
|
|
@@ -435,16 +435,16 @@ const testItems: ITestSuite = {
|
|
|
435
435
|
'rule': '?=hello',
|
|
436
436
|
'items': [
|
|
437
437
|
{
|
|
438
|
-
'
|
|
439
|
-
'
|
|
438
|
+
'title': 'string \'hello world\'',
|
|
439
|
+
'value': 'hello world',
|
|
440
440
|
'expect': true
|
|
441
441
|
},
|
|
442
442
|
{
|
|
443
|
-
'
|
|
444
|
-
'
|
|
443
|
+
'title': 'string \'hello world\'',
|
|
444
|
+
'value': 'Hello world',
|
|
445
445
|
'expect': false
|
|
446
446
|
},
|
|
447
|
-
...
|
|
447
|
+
...defaultItems({
|
|
448
448
|
'string \'hello\'': true,
|
|
449
449
|
'empty string': false
|
|
450
450
|
})
|
|
@@ -455,16 +455,16 @@ const testItems: ITestSuite = {
|
|
|
455
455
|
'rule': ':include:hello',
|
|
456
456
|
'items': [
|
|
457
457
|
{
|
|
458
|
-
'
|
|
459
|
-
'
|
|
458
|
+
'title': 'string \'hello world\'',
|
|
459
|
+
'value': 'hello world',
|
|
460
460
|
'expect': true
|
|
461
461
|
},
|
|
462
462
|
{
|
|
463
|
-
'
|
|
464
|
-
'
|
|
463
|
+
'title': 'string \'hello world\'',
|
|
464
|
+
'value': 'Hello world',
|
|
465
465
|
'expect': false
|
|
466
466
|
},
|
|
467
|
-
...
|
|
467
|
+
...defaultItems({
|
|
468
468
|
'string \'hello\'': true,
|
|
469
469
|
'empty string': false
|
|
470
470
|
})
|
|
@@ -475,16 +475,16 @@ const testItems: ITestSuite = {
|
|
|
475
475
|
'rule': '*=hello',
|
|
476
476
|
'items': [
|
|
477
477
|
{
|
|
478
|
-
'
|
|
479
|
-
'
|
|
478
|
+
'title': 'string \'hello world\'',
|
|
479
|
+
'value': 'hello world',
|
|
480
480
|
'expect': true
|
|
481
481
|
},
|
|
482
482
|
{
|
|
483
|
-
'
|
|
484
|
-
'
|
|
483
|
+
'title': 'string \'hello world\'',
|
|
484
|
+
'value': 'Hello world',
|
|
485
485
|
'expect': true
|
|
486
486
|
},
|
|
487
|
-
...
|
|
487
|
+
...defaultItems({
|
|
488
488
|
'string \'hello\'': true,
|
|
489
489
|
'empty string': false
|
|
490
490
|
})
|
|
@@ -495,16 +495,16 @@ const testItems: ITestSuite = {
|
|
|
495
495
|
'rule': ':include-i:hello',
|
|
496
496
|
'items': [
|
|
497
497
|
{
|
|
498
|
-
'
|
|
499
|
-
'
|
|
498
|
+
'title': 'string \'hello world\'',
|
|
499
|
+
'value': 'hello world',
|
|
500
500
|
'expect': true
|
|
501
501
|
},
|
|
502
502
|
{
|
|
503
|
-
'
|
|
504
|
-
'
|
|
503
|
+
'title': 'string \'hello world\'',
|
|
504
|
+
'value': 'Hello world',
|
|
505
505
|
'expect': true
|
|
506
506
|
},
|
|
507
|
-
...
|
|
507
|
+
...defaultItems({
|
|
508
508
|
'string \'hello\'': true,
|
|
509
509
|
'empty string': false
|
|
510
510
|
})
|
|
@@ -515,16 +515,16 @@ const testItems: ITestSuite = {
|
|
|
515
515
|
'rule': '?!hello',
|
|
516
516
|
'items': [
|
|
517
517
|
{
|
|
518
|
-
'
|
|
519
|
-
'
|
|
518
|
+
'title': 'string \'hello world\'',
|
|
519
|
+
'value': 'hello world',
|
|
520
520
|
'expect': false
|
|
521
521
|
},
|
|
522
522
|
{
|
|
523
|
-
'
|
|
524
|
-
'
|
|
523
|
+
'title': 'string \'hello world\'',
|
|
524
|
+
'value': 'Hello world',
|
|
525
525
|
'expect': true
|
|
526
526
|
},
|
|
527
|
-
...
|
|
527
|
+
...defaultItems({
|
|
528
528
|
'string \'hello\'': false,
|
|
529
529
|
'empty string': true
|
|
530
530
|
})
|
|
@@ -535,16 +535,16 @@ const testItems: ITestSuite = {
|
|
|
535
535
|
'rule': ':not-include:hello',
|
|
536
536
|
'items': [
|
|
537
537
|
{
|
|
538
|
-
'
|
|
539
|
-
'
|
|
538
|
+
'title': 'string \'hello world\'',
|
|
539
|
+
'value': 'hello world',
|
|
540
540
|
'expect': false
|
|
541
541
|
},
|
|
542
542
|
{
|
|
543
|
-
'
|
|
544
|
-
'
|
|
543
|
+
'title': 'string \'hello world\'',
|
|
544
|
+
'value': 'Hello world',
|
|
545
545
|
'expect': true
|
|
546
546
|
},
|
|
547
|
-
...
|
|
547
|
+
...defaultItems({
|
|
548
548
|
'string \'hello\'': false,
|
|
549
549
|
'empty string': true
|
|
550
550
|
})
|
|
@@ -555,16 +555,16 @@ const testItems: ITestSuite = {
|
|
|
555
555
|
'rule': ':not-include-i:hello',
|
|
556
556
|
'items': [
|
|
557
557
|
{
|
|
558
|
-
'
|
|
559
|
-
'
|
|
558
|
+
'title': 'string \'hello world\'',
|
|
559
|
+
'value': 'hello world',
|
|
560
560
|
'expect': false
|
|
561
561
|
},
|
|
562
562
|
{
|
|
563
|
-
'
|
|
564
|
-
'
|
|
563
|
+
'title': 'string \'hello world\'',
|
|
564
|
+
'value': 'Hello world',
|
|
565
565
|
'expect': false
|
|
566
566
|
},
|
|
567
|
-
...
|
|
567
|
+
...defaultItems({
|
|
568
568
|
'string \'hello\'': false,
|
|
569
569
|
'empty string': true
|
|
570
570
|
})
|
|
@@ -575,16 +575,16 @@ const testItems: ITestSuite = {
|
|
|
575
575
|
'rule': '*!hello',
|
|
576
576
|
'items': [
|
|
577
577
|
{
|
|
578
|
-
'
|
|
579
|
-
'
|
|
578
|
+
'title': 'string \'hello world\'',
|
|
579
|
+
'value': 'hello world',
|
|
580
580
|
'expect': false
|
|
581
581
|
},
|
|
582
582
|
{
|
|
583
|
-
'
|
|
584
|
-
'
|
|
583
|
+
'title': 'string \'hello world\'',
|
|
584
|
+
'value': 'Hello world',
|
|
585
585
|
'expect': false
|
|
586
586
|
},
|
|
587
|
-
...
|
|
587
|
+
...defaultItems({
|
|
588
588
|
'string \'hello\'': false,
|
|
589
589
|
'empty string': true
|
|
590
590
|
})
|
|
@@ -595,21 +595,21 @@ const testItems: ITestSuite = {
|
|
|
595
595
|
'rule': '~=/hello/i',
|
|
596
596
|
'items': [
|
|
597
597
|
{
|
|
598
|
-
'
|
|
599
|
-
'
|
|
598
|
+
'title': 'string \'hello world\'',
|
|
599
|
+
'value': 'hello world',
|
|
600
600
|
'expect': true
|
|
601
601
|
},
|
|
602
602
|
{
|
|
603
|
-
'
|
|
604
|
-
'
|
|
603
|
+
'title': 'string \'hello world\'',
|
|
604
|
+
'value': 'Hello world',
|
|
605
605
|
'expect': true
|
|
606
606
|
},
|
|
607
607
|
{
|
|
608
|
-
'
|
|
609
|
-
'
|
|
608
|
+
'title': 'string \'hi world\'',
|
|
609
|
+
'value': 'hi world',
|
|
610
610
|
'expect': false
|
|
611
611
|
},
|
|
612
|
-
...
|
|
612
|
+
...defaultItems({
|
|
613
613
|
'string \'hello\'': true,
|
|
614
614
|
'empty string': false
|
|
615
615
|
})
|
|
@@ -620,21 +620,21 @@ const testItems: ITestSuite = {
|
|
|
620
620
|
'rule': '~=hello',
|
|
621
621
|
'items': [
|
|
622
622
|
{
|
|
623
|
-
'
|
|
624
|
-
'
|
|
623
|
+
'title': 'string \'hello world\'',
|
|
624
|
+
'value': 'hello world',
|
|
625
625
|
'expect': true
|
|
626
626
|
},
|
|
627
627
|
{
|
|
628
|
-
'
|
|
629
|
-
'
|
|
628
|
+
'title': 'string \'hello world\'',
|
|
629
|
+
'value': 'Hello world',
|
|
630
630
|
'expect': false
|
|
631
631
|
},
|
|
632
632
|
{
|
|
633
|
-
'
|
|
634
|
-
'
|
|
633
|
+
'title': 'string \'hi world\'',
|
|
634
|
+
'value': 'hi world',
|
|
635
635
|
'expect': false
|
|
636
636
|
},
|
|
637
|
-
...
|
|
637
|
+
...defaultItems({
|
|
638
638
|
'string \'hello\'': true,
|
|
639
639
|
'empty string': false
|
|
640
640
|
})
|
|
@@ -645,21 +645,21 @@ const testItems: ITestSuite = {
|
|
|
645
645
|
'rule': '~/hello/i',
|
|
646
646
|
'items': [
|
|
647
647
|
{
|
|
648
|
-
'
|
|
649
|
-
'
|
|
648
|
+
'title': 'string \'hello world\'',
|
|
649
|
+
'value': 'hello world',
|
|
650
650
|
'expect': true
|
|
651
651
|
},
|
|
652
652
|
{
|
|
653
|
-
'
|
|
654
|
-
'
|
|
653
|
+
'title': 'string \'hello world\'',
|
|
654
|
+
'value': 'Hello world',
|
|
655
655
|
'expect': true
|
|
656
656
|
},
|
|
657
657
|
{
|
|
658
|
-
'
|
|
659
|
-
'
|
|
658
|
+
'title': 'string \'hi world\'',
|
|
659
|
+
'value': 'hi world',
|
|
660
660
|
'expect': false
|
|
661
661
|
},
|
|
662
|
-
...
|
|
662
|
+
...defaultItems({
|
|
663
663
|
'string \'hello\'': true,
|
|
664
664
|
'empty string': false
|
|
665
665
|
})
|
|
@@ -670,21 +670,21 @@ const testItems: ITestSuite = {
|
|
|
670
670
|
'rule': '~hello',
|
|
671
671
|
'items': [
|
|
672
672
|
{
|
|
673
|
-
'
|
|
674
|
-
'
|
|
673
|
+
'title': 'string \'hello world\'',
|
|
674
|
+
'value': 'hello world',
|
|
675
675
|
'expect': true
|
|
676
676
|
},
|
|
677
677
|
{
|
|
678
|
-
'
|
|
679
|
-
'
|
|
678
|
+
'title': 'string \'hello world\'',
|
|
679
|
+
'value': 'Hello world',
|
|
680
680
|
'expect': false
|
|
681
681
|
},
|
|
682
682
|
{
|
|
683
|
-
'
|
|
684
|
-
'
|
|
683
|
+
'title': 'string \'hi world\'',
|
|
684
|
+
'value': 'hi world',
|
|
685
685
|
'expect': false
|
|
686
686
|
},
|
|
687
|
-
...
|
|
687
|
+
...defaultItems({
|
|
688
688
|
'string \'hello\'': true,
|
|
689
689
|
'empty string': false
|
|
690
690
|
})
|
|
@@ -695,21 +695,21 @@ const testItems: ITestSuite = {
|
|
|
695
695
|
'rule': '~!hello',
|
|
696
696
|
'items': [
|
|
697
697
|
{
|
|
698
|
-
'
|
|
699
|
-
'
|
|
698
|
+
'title': 'string \'hello world\'',
|
|
699
|
+
'value': 'hello world',
|
|
700
700
|
'expect': false
|
|
701
701
|
},
|
|
702
702
|
{
|
|
703
|
-
'
|
|
704
|
-
'
|
|
703
|
+
'title': 'string \'hello world\'',
|
|
704
|
+
'value': 'Hello world',
|
|
705
705
|
'expect': true
|
|
706
706
|
},
|
|
707
707
|
{
|
|
708
|
-
'
|
|
709
|
-
'
|
|
708
|
+
'title': 'string \'hi world\'',
|
|
709
|
+
'value': 'hi world',
|
|
710
710
|
'expect': true
|
|
711
711
|
},
|
|
712
|
-
...
|
|
712
|
+
...defaultItems({
|
|
713
713
|
'string \'hello\'': false,
|
|
714
714
|
'empty string': true
|
|
715
715
|
})
|
|
@@ -720,21 +720,21 @@ const testItems: ITestSuite = {
|
|
|
720
720
|
'rule': '~!/hello/i',
|
|
721
721
|
'items': [
|
|
722
722
|
{
|
|
723
|
-
'
|
|
724
|
-
'
|
|
723
|
+
'title': 'string \'hello world\'',
|
|
724
|
+
'value': 'hello world',
|
|
725
725
|
'expect': false
|
|
726
726
|
},
|
|
727
727
|
{
|
|
728
|
-
'
|
|
729
|
-
'
|
|
728
|
+
'title': 'string \'hello world\'',
|
|
729
|
+
'value': 'Hello world',
|
|
730
730
|
'expect': false
|
|
731
731
|
},
|
|
732
732
|
{
|
|
733
|
-
'
|
|
734
|
-
'
|
|
733
|
+
'title': 'string \'hi world\'',
|
|
734
|
+
'value': 'hi world',
|
|
735
735
|
'expect': true
|
|
736
736
|
},
|
|
737
|
-
...
|
|
737
|
+
...defaultItems({
|
|
738
738
|
'string \'hello\'': false,
|
|
739
739
|
'empty string': true
|
|
740
740
|
})
|
|
@@ -745,21 +745,21 @@ const testItems: ITestSuite = {
|
|
|
745
745
|
'rule': '!~!/hello/i',
|
|
746
746
|
'items': [
|
|
747
747
|
{
|
|
748
|
-
'
|
|
749
|
-
'
|
|
748
|
+
'title': 'string \'hello world\'',
|
|
749
|
+
'value': 'hello world',
|
|
750
750
|
'expect': true
|
|
751
751
|
},
|
|
752
752
|
{
|
|
753
|
-
'
|
|
754
|
-
'
|
|
753
|
+
'title': 'string \'hello world\'',
|
|
754
|
+
'value': 'Hello world',
|
|
755
755
|
'expect': true
|
|
756
756
|
},
|
|
757
757
|
{
|
|
758
|
-
'
|
|
759
|
-
'
|
|
758
|
+
'title': 'string \'hi world\'',
|
|
759
|
+
'value': 'hi world',
|
|
760
760
|
'expect': false
|
|
761
761
|
},
|
|
762
|
-
...
|
|
762
|
+
...defaultItems({
|
|
763
763
|
'empty string': false
|
|
764
764
|
}, true)
|
|
765
765
|
]
|
|
@@ -769,21 +769,21 @@ const testItems: ITestSuite = {
|
|
|
769
769
|
'rule': ['$.not', '~!/hello/i'],
|
|
770
770
|
'items': [
|
|
771
771
|
{
|
|
772
|
-
'
|
|
773
|
-
'
|
|
772
|
+
'title': 'string \'hello world\'',
|
|
773
|
+
'value': 'hello world',
|
|
774
774
|
'expect': true
|
|
775
775
|
},
|
|
776
776
|
{
|
|
777
|
-
'
|
|
778
|
-
'
|
|
777
|
+
'title': 'string \'hello world\'',
|
|
778
|
+
'value': 'Hello world',
|
|
779
779
|
'expect': true
|
|
780
780
|
},
|
|
781
781
|
{
|
|
782
|
-
'
|
|
783
|
-
'
|
|
782
|
+
'title': 'string \'hi world\'',
|
|
783
|
+
'value': 'hi world',
|
|
784
784
|
'expect': false
|
|
785
785
|
},
|
|
786
|
-
...
|
|
786
|
+
...defaultItems({
|
|
787
787
|
'empty string': false
|
|
788
788
|
}, true)
|
|
789
789
|
]
|