wisp-schema 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/wisp-schema.rb +7 -0
- data/wisp.json +462 -0
- metadata +47 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 5234655066185960baf7e6dd335407a08a0972258c9cea6dc41e6373b41290a2
|
4
|
+
data.tar.gz: 66e415f68ff4b5ccd7a640a55ea6997bae70c74fdcd15267da092a7ee50d70c2
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 56ceee9cf9a97d0a9009b7683dffaa8b3ac5039c7a120ca68d7399f19753440a60c4bd4fcee324239012d77e179b08e6a35779ebed50c8d766bb833a5bf1a759
|
7
|
+
data.tar.gz: 29764efd8c35f3418dfa5484f2341c288ba06735d3a51f813455a020ac39dc15c6f6e98a83d6122c55c96a3bc7e682780aa1bba7efcd058e38c1722adc121311
|
data/lib/wisp-schema.rb
ADDED
data/wisp.json
ADDED
@@ -0,0 +1,462 @@
|
|
1
|
+
{
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
3
|
+
"definitions": {
|
4
|
+
"noun": {
|
5
|
+
"title": "Wisp Noun",
|
6
|
+
"oneOf": [
|
7
|
+
{"$ref": "#/definitions/button"},
|
8
|
+
{"$ref": "#/definitions/field"},
|
9
|
+
{"$ref": "#/definitions/dropdown"},
|
10
|
+
{"$ref": "#/definitions/dropdown_option"},
|
11
|
+
{"$ref": "#/definitions/link"},
|
12
|
+
{"$ref": "#/definitions/icon"},
|
13
|
+
{"$ref": "#/definitions/checkbox"},
|
14
|
+
{"$ref": "#/definitions/header"},
|
15
|
+
{"$ref": "#/definitions/window"},
|
16
|
+
{"$ref": "#/definitions/modal"},
|
17
|
+
{"$ref": "#/definitions/text"},
|
18
|
+
{"$ref": "#/definitions/ui_element"}
|
19
|
+
]
|
20
|
+
},
|
21
|
+
"button": {
|
22
|
+
"type": "object",
|
23
|
+
"title": "Button",
|
24
|
+
"description": "Button",
|
25
|
+
"properties": {
|
26
|
+
"type": {
|
27
|
+
"enum": ["BUTTON"]
|
28
|
+
},
|
29
|
+
"label": {"title": "Label", "type": "string"}
|
30
|
+
},
|
31
|
+
"required": ["type", "label"]
|
32
|
+
},
|
33
|
+
"field": {
|
34
|
+
"type": "object",
|
35
|
+
"title": "Field",
|
36
|
+
"description": "Text Field",
|
37
|
+
"properties": {
|
38
|
+
"type": {
|
39
|
+
"enum": ["TEXT_FIELD"]
|
40
|
+
},
|
41
|
+
"label": {"title": "Label", "type": "string"}
|
42
|
+
},
|
43
|
+
"required": ["type", "label"]
|
44
|
+
},
|
45
|
+
"dropdown": {
|
46
|
+
"type": "object",
|
47
|
+
"title": "Dropdown",
|
48
|
+
"description": "Dropdown",
|
49
|
+
"properties": {
|
50
|
+
"type": {
|
51
|
+
"enum": ["DROPDOWN"]
|
52
|
+
},
|
53
|
+
"label": {"title": "Label", "type": "string"}
|
54
|
+
},
|
55
|
+
"required": ["type", "label"]
|
56
|
+
},
|
57
|
+
"dropdown_option": {
|
58
|
+
"type": "object",
|
59
|
+
"title": "Dropdown Option",
|
60
|
+
"description": "Option in open dropdown",
|
61
|
+
"properties": {
|
62
|
+
"type": {
|
63
|
+
"enum": ["DROPDOWN_OPTION"]
|
64
|
+
},
|
65
|
+
"label": {"title": "Label", "type": "string"}
|
66
|
+
},
|
67
|
+
"required": ["type", "label"]
|
68
|
+
},
|
69
|
+
"link": {
|
70
|
+
"type": "object",
|
71
|
+
"title": "Link",
|
72
|
+
"description": "Link",
|
73
|
+
"properties": {
|
74
|
+
"type": {
|
75
|
+
"enum": ["LINK"]
|
76
|
+
},
|
77
|
+
"text": {"title": "Text", "type": "string"}
|
78
|
+
},
|
79
|
+
"required": ["type", "text"]
|
80
|
+
},
|
81
|
+
"icon": {
|
82
|
+
"type": "object",
|
83
|
+
"title": "Icon",
|
84
|
+
"description": "Icon",
|
85
|
+
"properties": {
|
86
|
+
"type": {
|
87
|
+
"enum": ["ICON"]
|
88
|
+
},
|
89
|
+
"description": {"title": "Description", "type": "string"}
|
90
|
+
},
|
91
|
+
"required": ["type", "description"]
|
92
|
+
},
|
93
|
+
"checkbox": {
|
94
|
+
"type": "object",
|
95
|
+
"title": "Checkbox",
|
96
|
+
"description": "Checkbox",
|
97
|
+
"properties": {
|
98
|
+
"type": {
|
99
|
+
"enum": ["CHECKBOX"]
|
100
|
+
},
|
101
|
+
"label": {"title": "Label", "type": "string"}
|
102
|
+
},
|
103
|
+
"required": ["type", "label"]
|
104
|
+
},
|
105
|
+
"header": {
|
106
|
+
"type": "object",
|
107
|
+
"title": "Header",
|
108
|
+
"description": "Page Header",
|
109
|
+
"properties": {
|
110
|
+
"type": {
|
111
|
+
"enum": ["HEADER"]
|
112
|
+
},
|
113
|
+
"text": {"title": "Text", "type": "string"}
|
114
|
+
},
|
115
|
+
"required": ["type", "text"]
|
116
|
+
},
|
117
|
+
"window": {
|
118
|
+
"type": "object",
|
119
|
+
"title": "Window",
|
120
|
+
"description": "Any pop-up window",
|
121
|
+
"properties": {
|
122
|
+
"type": {
|
123
|
+
"enum": ["WINDOW"]
|
124
|
+
},
|
125
|
+
"description": {"title": "Description", "type": "string"}
|
126
|
+
},
|
127
|
+
"required": ["type", "description"]
|
128
|
+
},
|
129
|
+
"modal": {
|
130
|
+
"type": "object",
|
131
|
+
"title": "Modal",
|
132
|
+
"description": "In page modal",
|
133
|
+
"properties": {
|
134
|
+
"type": {
|
135
|
+
"enum": ["MODAL"]
|
136
|
+
},
|
137
|
+
"description": {"title": "Description", "type": "string"}
|
138
|
+
},
|
139
|
+
"required": ["type", "description"]
|
140
|
+
},
|
141
|
+
"text": {
|
142
|
+
"type": "object",
|
143
|
+
"title": "Text",
|
144
|
+
"description": "Exactly matched text",
|
145
|
+
"properties": {
|
146
|
+
"type": {
|
147
|
+
"enum": ["TEXT"]
|
148
|
+
},
|
149
|
+
"text": {"title": "Text", "type": "string"}
|
150
|
+
},
|
151
|
+
"required": ["type", "text"]
|
152
|
+
},
|
153
|
+
"ui_element": {
|
154
|
+
"type": "object",
|
155
|
+
"title": "UI Element",
|
156
|
+
"description": "Any other UI Element",
|
157
|
+
"properties": {
|
158
|
+
"type": {
|
159
|
+
"enum": ["UI_ELEMENT"]
|
160
|
+
},
|
161
|
+
"element": {"title": "Element", "type": "string"}
|
162
|
+
},
|
163
|
+
"required": ["type", "element"]
|
164
|
+
},
|
165
|
+
"verb": {
|
166
|
+
"title": "Wisp Verb",
|
167
|
+
"oneOf": [
|
168
|
+
{"$ref": "#/definitions/click"},
|
169
|
+
{"$ref": "#/definitions/fill"},
|
170
|
+
{"$ref": "#/definitions/type"},
|
171
|
+
{"$ref": "#/definitions/send_key"},
|
172
|
+
{"$ref": "#/definitions/hover"},
|
173
|
+
{"$ref": "#/definitions/dropdown_select"},
|
174
|
+
{"$ref": "#/definitions/checkbox_check"},
|
175
|
+
{"$ref": "#/definitions/checkbox_uncheck"},
|
176
|
+
{"$ref": "#/definitions/refresh"},
|
177
|
+
{"$ref": "#/definitions/navigate"},
|
178
|
+
{"$ref": "#/definitions/navigate_new_tab"},
|
179
|
+
{"$ref": "#/definitions/navigate_incognito_tab"},
|
180
|
+
{"$ref": "#/definitions/close_tab"},
|
181
|
+
{"$ref": "#/definitions/scroll"},
|
182
|
+
{"$ref": "#/definitions/drag_and_drop"},
|
183
|
+
{"$ref": "#/definitions/click_and_hold"},
|
184
|
+
{"$ref": "#/definitions/plain_language"},
|
185
|
+
{"$ref": "#/definitions/see"},
|
186
|
+
{"$ref": "#/definitions/disappear"},
|
187
|
+
{"$ref": "#/definitions/loaded"},
|
188
|
+
{"$ref": "#/definitions/plain_language_assertion"}
|
189
|
+
]
|
190
|
+
},
|
191
|
+
"click": {
|
192
|
+
"type": "object",
|
193
|
+
"title": "Click",
|
194
|
+
"description": "Clicks on the UI element",
|
195
|
+
"properties": {
|
196
|
+
"action": {
|
197
|
+
"enum": ["CLICK"]
|
198
|
+
},
|
199
|
+
"target": {"$ref": "#/definitions/noun"}
|
200
|
+
},
|
201
|
+
"required": ["action", "target"]
|
202
|
+
},
|
203
|
+
"fill": {
|
204
|
+
"type": "object",
|
205
|
+
"title": "Fill",
|
206
|
+
"description": "Fills the text field with specified content",
|
207
|
+
"properties": {
|
208
|
+
"action": {
|
209
|
+
"enum": ["FILL"]
|
210
|
+
},
|
211
|
+
"text": {"title": "Text", "type": "string"},
|
212
|
+
"target": {"$ref": "#/definitions/noun"}
|
213
|
+
},
|
214
|
+
"required": ["action", "target", "text"]
|
215
|
+
},
|
216
|
+
"type": {
|
217
|
+
"type": "object",
|
218
|
+
"title": "Type",
|
219
|
+
"description": "Types in specified text",
|
220
|
+
"properties": {
|
221
|
+
"action": {
|
222
|
+
"enum": ["TYPE"]
|
223
|
+
},
|
224
|
+
"text": {"title": "Text", "type": "string"}
|
225
|
+
},
|
226
|
+
"required": ["action", "text"]
|
227
|
+
},
|
228
|
+
"send_key": {
|
229
|
+
"type": "object",
|
230
|
+
"title": "Send Key",
|
231
|
+
"description": "Sends key combination",
|
232
|
+
"properties": {
|
233
|
+
"action": {
|
234
|
+
"enum": ["SEND_KEY"]
|
235
|
+
},
|
236
|
+
"modifier": {"title": "Modifier", "type": "string"},
|
237
|
+
"key": {"title": "Key", "type": "string"}
|
238
|
+
},
|
239
|
+
"required": ["action", "key"]
|
240
|
+
},
|
241
|
+
"hover": {
|
242
|
+
"type": "object",
|
243
|
+
"title": "Hover",
|
244
|
+
"description": "Hovers over specified element",
|
245
|
+
"properties": {
|
246
|
+
"action": {
|
247
|
+
"enum": ["HOVER"]
|
248
|
+
},
|
249
|
+
"target": {"$ref": "#/definitions/noun"}
|
250
|
+
},
|
251
|
+
"required": ["action", "target"]
|
252
|
+
},
|
253
|
+
"dropdown_select": {
|
254
|
+
"type": "object",
|
255
|
+
"title": "Dropdown Select",
|
256
|
+
"description": "Selects specified item from the dropdown",
|
257
|
+
"properties": {
|
258
|
+
"action": {
|
259
|
+
"enum": ["DROPDOWN_SELECT"]
|
260
|
+
},
|
261
|
+
"target": {"$ref": "#/definitions/noun"},
|
262
|
+
"option": {"title": "Option", "type": "string"}
|
263
|
+
},
|
264
|
+
"required": ["action", "target"]
|
265
|
+
},
|
266
|
+
"checkbox_check": {
|
267
|
+
"type": "object",
|
268
|
+
"title": "Checkbox Check",
|
269
|
+
"description": "Checks specified checkbox",
|
270
|
+
"properties": {
|
271
|
+
"action": {
|
272
|
+
"enum": ["CHECKBOX_CHECK"]
|
273
|
+
},
|
274
|
+
"target": {"$ref": "#/definitions/noun"}
|
275
|
+
},
|
276
|
+
"required": ["action", "target"]
|
277
|
+
},
|
278
|
+
"checkbox_uncheck": {
|
279
|
+
"type": "object",
|
280
|
+
"title": "Checkbox Uncheck",
|
281
|
+
"description": "Unhecks specified checkbox",
|
282
|
+
"properties": {
|
283
|
+
"action": {
|
284
|
+
"enum": ["CHECKBOX_UNCHECK"]
|
285
|
+
},
|
286
|
+
"target": {"$ref": "#/definitions/noun"}
|
287
|
+
},
|
288
|
+
"required": ["action", "target"]
|
289
|
+
},
|
290
|
+
"refresh": {
|
291
|
+
"type": "object",
|
292
|
+
"title": "Refresh",
|
293
|
+
"description": "Refreshes the webpage",
|
294
|
+
"properties": {
|
295
|
+
"action": {
|
296
|
+
"enum": ["REFRESH"]
|
297
|
+
}
|
298
|
+
},
|
299
|
+
"required": ["action"]
|
300
|
+
},
|
301
|
+
"navigate": {
|
302
|
+
"type": "object",
|
303
|
+
"title": "Navigate",
|
304
|
+
"description": "Navigates to specified URL",
|
305
|
+
"properties": {
|
306
|
+
"action": {
|
307
|
+
"enum": ["NAVIGATE"]
|
308
|
+
},
|
309
|
+
"url": {"title": "URL", "type": "string"}
|
310
|
+
},
|
311
|
+
"required": ["action", "url"]
|
312
|
+
},
|
313
|
+
"navigate_new_tab": {
|
314
|
+
"type": "object",
|
315
|
+
"title": "Navigate - New Tab",
|
316
|
+
"description": "Navigates to specified URL in a new tab",
|
317
|
+
"properties": {
|
318
|
+
"action": {
|
319
|
+
"enum": ["NAVIGATE_NEW_TAB"]
|
320
|
+
},
|
321
|
+
"url": {"title": "URL", "type": "string"}
|
322
|
+
},
|
323
|
+
"required": ["action", "url"]
|
324
|
+
},
|
325
|
+
"navigate_incognito_tab": {
|
326
|
+
"type": "object",
|
327
|
+
"title": "Navigate - Incognito Tab",
|
328
|
+
"description": "Navigates to specified URL in a new incognito tab",
|
329
|
+
"properties": {
|
330
|
+
"action": {
|
331
|
+
"enum": ["NAVIGATE_INCOGNITO_TAB"]
|
332
|
+
},
|
333
|
+
"url": {"title": "URL", "type": "string"}
|
334
|
+
},
|
335
|
+
"required": ["action", "url"]
|
336
|
+
},
|
337
|
+
"close_tab": {
|
338
|
+
"type": "object",
|
339
|
+
"title": "Close Tab",
|
340
|
+
"description": "Closes current browser tab",
|
341
|
+
"properties": {
|
342
|
+
"action": {
|
343
|
+
"enum": ["CLOSE_TAB"]
|
344
|
+
}
|
345
|
+
},
|
346
|
+
"required": ["action"]
|
347
|
+
},
|
348
|
+
"scroll": {
|
349
|
+
"type": "object",
|
350
|
+
"title": "Scroll",
|
351
|
+
"description": "Scrolls the page into specified direction until target is reached",
|
352
|
+
"properties": {
|
353
|
+
"action": {
|
354
|
+
"enum": ["SCROLL"]
|
355
|
+
},
|
356
|
+
"target": {"$ref": "#/definitions/noun"},
|
357
|
+
"direction": {"title": "Direction", "type": "string"}
|
358
|
+
},
|
359
|
+
"required": ["action", "direction"]
|
360
|
+
},
|
361
|
+
"drag_and_drop": {
|
362
|
+
"type": "object",
|
363
|
+
"title": "Drag and drop",
|
364
|
+
"description": "Drag and drop",
|
365
|
+
"properties": {
|
366
|
+
"action": {
|
367
|
+
"enum": ["DRAG_AND_DROP"]
|
368
|
+
},
|
369
|
+
"target": {"$ref": "#/definitions/noun"},
|
370
|
+
"object": {"title": "Object", "type": "string"}
|
371
|
+
},
|
372
|
+
"required": ["action", "target", "object"]
|
373
|
+
},
|
374
|
+
"click_and_hold": {
|
375
|
+
"type": "object",
|
376
|
+
"title": "Click and Hold",
|
377
|
+
"description": "Clicks and holds mouse button over object",
|
378
|
+
"properties": {
|
379
|
+
"action": {
|
380
|
+
"enum": ["CLICK_AND_HOLD"]
|
381
|
+
},
|
382
|
+
"target": {"$ref": "#/definitions/noun"},
|
383
|
+
"seconds": {"title": "Seconds", "type": "integer"}
|
384
|
+
},
|
385
|
+
"required": ["action", "target", "seconds"]
|
386
|
+
},
|
387
|
+
"plain_language": {
|
388
|
+
"type": "object",
|
389
|
+
"title": "Plain Language",
|
390
|
+
"description": "Allows to fallback to english",
|
391
|
+
"properties": {
|
392
|
+
"action": {
|
393
|
+
"enum": ["PLAIN_LANGUAGE"]
|
394
|
+
},
|
395
|
+
"instruction": {"title": "Instruction", "type": "string"}
|
396
|
+
},
|
397
|
+
"required": ["action", "instruction"]
|
398
|
+
},
|
399
|
+
"see": {
|
400
|
+
"type": "object",
|
401
|
+
"title": "See",
|
402
|
+
"description": "Checks if element of the UI is visible",
|
403
|
+
"properties": {
|
404
|
+
"assertion": {
|
405
|
+
"enum": ["SEE"]
|
406
|
+
},
|
407
|
+
"object": {"$ref": "#/definitions/noun"}
|
408
|
+
},
|
409
|
+
"required": ["assertion", "object"]
|
410
|
+
},
|
411
|
+
"disappear": {
|
412
|
+
"type": "object",
|
413
|
+
"title": "Disappear",
|
414
|
+
"description": "Checks if element of the UI is no longer visible",
|
415
|
+
"properties": {
|
416
|
+
"assertion": {
|
417
|
+
"enum": ["DISAPPEAR"]
|
418
|
+
},
|
419
|
+
"object": {"$ref": "#/definitions/noun"}
|
420
|
+
},
|
421
|
+
"required": ["assertion", "object"]
|
422
|
+
},
|
423
|
+
"loaded": {
|
424
|
+
"type": "object",
|
425
|
+
"title": "Loaded",
|
426
|
+
"description": "Checks if specified page has loaded",
|
427
|
+
"properties": {
|
428
|
+
"assertion": {
|
429
|
+
"enum": ["LOADED"]
|
430
|
+
},
|
431
|
+
"page": {"title": "Page", "type": "string"}
|
432
|
+
},
|
433
|
+
"required": ["assertion", "page"]
|
434
|
+
},
|
435
|
+
"plain_language_assertion": {
|
436
|
+
"type": "object",
|
437
|
+
"title": "Plain Language Assertion",
|
438
|
+
"description": "Allows to fallback to english",
|
439
|
+
"properties": {
|
440
|
+
"assertion": {
|
441
|
+
"enum": ["PLAIN_LANGUAGE"]
|
442
|
+
},
|
443
|
+
"instruction": {"title": "Instruction", "type": "string"}
|
444
|
+
},
|
445
|
+
"required": ["assertion", "instruction"]
|
446
|
+
}
|
447
|
+
},
|
448
|
+
"type": "object",
|
449
|
+
"title": "Wisp Test",
|
450
|
+
"properties": {
|
451
|
+
"version": {
|
452
|
+
"type": "integer"
|
453
|
+
},
|
454
|
+
"verbs": {
|
455
|
+
"type": "array",
|
456
|
+
"items": {
|
457
|
+
"$ref": "#/definitions/verb"
|
458
|
+
}
|
459
|
+
}
|
460
|
+
},
|
461
|
+
"required": ["version", "verbs"]
|
462
|
+
}
|
metadata
ADDED
@@ -0,0 +1,47 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: wisp-schema
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Jan Grodowski
|
8
|
+
- Maciej Siwek
|
9
|
+
- Bartosz Kruszczynski
|
10
|
+
autorequire:
|
11
|
+
bindir: bin
|
12
|
+
cert_chain: []
|
13
|
+
date: 2018-11-15 00:00:00.000000000 Z
|
14
|
+
dependencies: []
|
15
|
+
description: This gem contains Wisp's JSON schema definition
|
16
|
+
email:
|
17
|
+
executables: []
|
18
|
+
extensions: []
|
19
|
+
extra_rdoc_files: []
|
20
|
+
files:
|
21
|
+
- lib/wisp-schema.rb
|
22
|
+
- wisp.json
|
23
|
+
homepage: https://github.com/rainforestapp/wisp
|
24
|
+
licenses:
|
25
|
+
- MIT
|
26
|
+
metadata: {}
|
27
|
+
post_install_message:
|
28
|
+
rdoc_options: []
|
29
|
+
require_paths:
|
30
|
+
- lib
|
31
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
32
|
+
requirements:
|
33
|
+
- - ">="
|
34
|
+
- !ruby/object:Gem::Version
|
35
|
+
version: '0'
|
36
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
requirements: []
|
42
|
+
rubyforge_project:
|
43
|
+
rubygems_version: 2.7.8
|
44
|
+
signing_key:
|
45
|
+
specification_version: 4
|
46
|
+
summary: Wisp's schema
|
47
|
+
test_files: []
|