@scalable.software/pin 0.2.0 → 0.2.1

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.
@@ -1,416 +1,464 @@
1
1
  [
2
2
  {
3
- "type": "Metadata",
4
- "spec": "State",
3
+ "type": "Event",
4
+ "spec": "onshow",
5
5
  "definition": [
6
- "Given Metadata.STATE Type.Metadata test",
7
- "and Status imported",
8
- "and Status is defined",
9
- "then Status is an object"
6
+ "Event.onshow test",
7
+ "and Pin is defined in custom element registry",
8
+ "and HTML Template is added to DOM",
9
+ "and a new pin is added to DOM",
10
+ "then pin.onshow setter is defined"
10
11
  ],
11
12
  "status": "pass"
12
13
  },
13
14
  {
14
- "type": "Metadata",
15
- "spec": "State",
15
+ "type": "Event",
16
+ "spec": "onshow",
16
17
  "definition": [
17
- "Given Metadata.STATE Type.Metadata test",
18
- "and Status imported",
19
- "and Status is defined",
20
- "and Status is an object",
21
- "then Status contains pinned"
18
+ "Event.onshow test",
19
+ "and Pin is defined in custom element registry",
20
+ "and HTML Template is added to DOM",
21
+ "and a new pin is added to DOM",
22
+ "and pin.visible is set to Visible.NO",
23
+ "and pin.onshow setter is defined",
24
+ "when pin.visible set to Visible.YES",
25
+ "then onshow is called with `visible: Visible.YES`"
22
26
  ],
23
27
  "status": "pass"
24
28
  },
25
29
  {
26
- "type": "Metadata",
27
- "spec": "State",
30
+ "type": "Event",
31
+ "spec": "onshow",
28
32
  "definition": [
29
- "Given Metadata.STATE Type.Metadata test",
30
- "and Status imported",
31
- "and Status is defined",
32
- "and Status is an object",
33
- "then Status contains unpinned"
33
+ "Event.onshow test",
34
+ "and Pin is defined in custom element registry",
35
+ "and HTML Template is added to DOM",
36
+ "and a new pin is added to DOM",
37
+ "and pin.visible is set to Visible.NO",
38
+ "and pin.onshow setter is defined",
39
+ "when pin.visible set to Visible.YES",
40
+ "then onshow is called"
34
41
  ],
35
42
  "status": "pass"
36
43
  },
37
44
  {
38
- "type": "Metadata",
39
- "spec": "State",
45
+ "type": "Event",
46
+ "spec": "onshow",
40
47
  "definition": [
41
- "Given Metadata.STATE Type.Metadata test",
42
- "and Status imported",
43
- "then Status is defined"
48
+ "Event.onshow test",
49
+ "and Pin is defined in custom element registry",
50
+ "and HTML Template is added to DOM",
51
+ "and a new pin is added to DOM",
52
+ "and pin.visible is set to Visible.NO",
53
+ "and pin.onshow setter is defined",
54
+ "and pin.onshow is set to new listener ",
55
+ "when pin.visible set to Visible.YES",
56
+ "then onshow2 is called"
44
57
  ],
45
58
  "status": "pass"
46
59
  },
47
60
  {
48
- "type": "Metadata",
49
- "spec": "State",
61
+ "type": "Event",
62
+ "spec": "onshow",
50
63
  "definition": [
51
- "Given Metadata.STATE Type.Metadata test",
52
- "and Visible imported",
53
- "then Visible is defined"
64
+ "Event.onshow test",
65
+ "and Pin is defined in custom element registry",
66
+ "and HTML Template is added to DOM",
67
+ "and a new pin is added to DOM",
68
+ "and pin.visible is set to Visible.NO",
69
+ "and pin.onshow setter is defined",
70
+ "and pin.onshow is set to new listener ",
71
+ "when pin.visible set to Visible.YES",
72
+ "then onshow is not called"
54
73
  ],
55
74
  "status": "pass"
56
75
  },
57
76
  {
58
- "type": "Metadata",
59
- "spec": "State",
77
+ "type": "Gesture",
78
+ "spec": "click",
60
79
  "definition": [
61
- "Given Metadata.STATE Type.Metadata test",
62
- "and Visible imported",
63
- "and Visible is defined",
64
- "and Visible is an object",
65
- "then Visible contains yes"
80
+ "Gesture.click test",
81
+ "and Pin is defined in custom element registry",
82
+ "and HTML Template is added to DOM",
83
+ "and a new pin is added to DOM",
84
+ "when user click on icon",
85
+ "then pin.status is State.PINNED"
66
86
  ],
67
87
  "status": "pass"
68
88
  },
69
89
  {
70
- "type": "Metadata",
71
- "spec": "State",
90
+ "type": "Gesture",
91
+ "spec": "click",
72
92
  "definition": [
73
- "Given Metadata.STATE Type.Metadata test",
74
- "and Visible imported",
75
- "and Visible is defined",
76
- "and Visible is an object",
77
- "then Visible contains no"
93
+ "Gesture.click test",
94
+ "and Pin is defined in custom element registry",
95
+ "and HTML Template is added to DOM",
96
+ "and a new pin is added to DOM",
97
+ "when user click on icon",
98
+ "then onpin is called"
78
99
  ],
79
100
  "status": "pass"
80
101
  },
81
102
  {
82
- "type": "Metadata",
83
- "spec": "State",
103
+ "type": "Gesture",
104
+ "spec": "click",
84
105
  "definition": [
85
- "Given Metadata.STATE Type.Metadata test",
86
- "and Visible imported",
87
- "and Visible is defined",
88
- "then Visible is an object"
106
+ "Gesture.click test",
107
+ "and Pin is defined in custom element registry",
108
+ "and HTML Template is added to DOM",
109
+ "and a new pin is added to DOM",
110
+ "when user click on icon",
111
+ "and user clicks on pin",
112
+ "then onunpin is called"
89
113
  ],
90
114
  "status": "pass"
91
115
  },
92
116
  {
93
- "type": "composition",
94
- "spec": "Template",
117
+ "type": "Gesture",
118
+ "spec": "click",
95
119
  "definition": [
96
- "Composition.Template test",
97
- "Given Pin is defined in custom element registry",
120
+ "Gesture.click test",
121
+ "and Pin is defined in custom element registry",
98
122
  "and HTML Template is added to DOM",
99
- "and template is defined",
100
- "and template contains div with class `icon`",
101
- "then div with class `icon` contain svg with class `pinned`"
123
+ "and a new pin is added to DOM",
124
+ "when user click on icon",
125
+ "and user clicks on pin",
126
+ "then pin.status is Status.UNPINNED"
102
127
  ],
103
128
  "status": "pass"
104
129
  },
105
130
  {
106
- "type": "composition",
107
- "spec": "Template",
131
+ "type": "Event",
132
+ "spec": "onpin",
108
133
  "definition": [
109
- "Composition.Template test",
110
- "Given Pin is defined in custom element registry",
134
+ "Event.onpin test",
135
+ "and Pin is defined in custom element registry",
111
136
  "and HTML Template is added to DOM",
112
- "and template is defined",
113
- "and template contains div with class `icon`",
114
- "then div with class `icon` contain svg with class `unpinned`"
137
+ "and a new pin is added to DOM",
138
+ "then pin.onpin setter is defined"
115
139
  ],
116
140
  "status": "pass"
117
141
  },
118
142
  {
119
- "type": "composition",
120
- "spec": "Template",
143
+ "type": "Event",
144
+ "spec": "onpin",
121
145
  "definition": [
122
- "Composition.Template test",
123
- "Given Pin is defined in custom element registry",
146
+ "Event.onpin test",
147
+ "and Pin is defined in custom element registry",
124
148
  "and HTML Template is added to DOM",
125
- "and template is defined",
126
- "then template contains div with class `icon`"
149
+ "and a new pin is added to DOM",
150
+ "and pin.onpin setter is defined",
151
+ "when pin.status set to Status.PINNED",
152
+ "then onpin is called with `status: Status.PINNED`"
127
153
  ],
128
154
  "status": "pass"
129
155
  },
130
156
  {
131
- "type": "composition",
132
- "spec": "Template",
157
+ "type": "Event",
158
+ "spec": "onpin",
133
159
  "definition": [
134
- "Composition.Template test",
135
- "Given Pin is defined in custom element registry",
160
+ "Event.onpin test",
161
+ "and Pin is defined in custom element registry",
136
162
  "and HTML Template is added to DOM",
137
163
  "and a new pin is added to DOM",
138
- "and pin.elements.icon is defined",
139
- "then pin.elements.icon is an HTMLDivElement"
164
+ "and pin.onpin setter is defined",
165
+ "and pin.onpin is set to new listener ",
166
+ "when pin.status set to Status.PINNED",
167
+ "then onpin2 is called"
140
168
  ],
141
169
  "status": "pass"
142
170
  },
143
171
  {
144
- "type": "composition",
145
- "spec": "Template",
172
+ "type": "Event",
173
+ "spec": "onpin",
146
174
  "definition": [
147
- "Composition.Template test",
148
- "Given Pin is defined in custom element registry",
175
+ "Event.onpin test",
176
+ "and Pin is defined in custom element registry",
149
177
  "and HTML Template is added to DOM",
150
178
  "and a new pin is added to DOM",
151
- "then pin.elements.icon is defined"
179
+ "and pin.onpin setter is defined",
180
+ "and pin.onpin is set to new listener ",
181
+ "when pin.status set to Status.PINNED",
182
+ "then onpin is not called"
152
183
  ],
153
184
  "status": "pass"
154
185
  },
155
186
  {
156
187
  "type": "composition",
157
- "spec": "Template",
188
+ "spec": "CSS",
158
189
  "definition": [
159
- "Composition.Template test",
190
+ "Composition.CSS test",
160
191
  "Given Pin is defined in custom element registry",
161
192
  "and HTML Template is added to DOM",
162
193
  "and a new pin is added to DOM",
163
- "then pin.root contents contains template contents"
194
+ "then pin.root contents contains a link to stylesheet"
164
195
  ],
165
196
  "status": "pass"
166
197
  },
167
198
  {
168
- "type": "composition",
169
- "spec": "Template",
199
+ "type": "Metadata",
200
+ "spec": "States",
170
201
  "definition": [
171
- "Composition.Template test",
172
- "Given Pin is defined in custom element registry",
173
- "and HTML Template is added to DOM",
174
- "then template is defined"
202
+ "Metadata.States test",
203
+ "and State imported",
204
+ "when State is defined",
205
+ "then State is an object"
175
206
  ],
176
207
  "status": "pass"
177
208
  },
178
209
  {
179
210
  "type": "Metadata",
180
- "spec": "Event",
211
+ "spec": "States",
181
212
  "definition": [
182
- "Given Metadata.EVENT Type.Metadata test",
183
- "and Event imported",
184
- "when Event is defined",
185
- "and Event is an object",
186
- "then Event.ON is defined"
213
+ "Metadata.States test",
214
+ "and State imported",
215
+ "when State is defined",
216
+ "and State is an object",
217
+ "then State contains visible"
187
218
  ],
188
219
  "status": "pass"
189
220
  },
190
221
  {
191
222
  "type": "Metadata",
192
- "spec": "Event",
223
+ "spec": "States",
193
224
  "definition": [
194
- "Given Metadata.EVENT Type.Metadata test",
195
- "and Event imported",
196
- "when Event is defined",
197
- "and Event is an object",
198
- "then Event.ON_HIDE is defined"
225
+ "Metadata.States test",
226
+ "and State imported",
227
+ "when State is defined",
228
+ "and State is an object",
229
+ "then State contains status"
199
230
  ],
200
231
  "status": "pass"
201
232
  },
202
233
  {
203
234
  "type": "Metadata",
204
- "spec": "Event",
235
+ "spec": "States",
205
236
  "definition": [
206
- "Given Metadata.EVENT Type.Metadata test",
207
- "and Event imported",
208
- "when Event is defined",
209
- "and Event is an object",
210
- "then Event.ON_SHOW is defined"
237
+ "Metadata.States test",
238
+ "and State imported",
239
+ "when State is defined",
240
+ "and State is an object",
241
+ "and Visible imported",
242
+ "then Visible is defined"
211
243
  ],
212
244
  "status": "pass"
213
245
  },
214
246
  {
215
247
  "type": "Metadata",
216
- "spec": "Event",
248
+ "spec": "States",
217
249
  "definition": [
218
- "Given Metadata.EVENT Type.Metadata test",
219
- "and Event imported",
220
- "when Event is defined",
221
- "and Event is an object",
222
- "then Event.ON_UNPIN is defined"
250
+ "Metadata.States test",
251
+ "and State imported",
252
+ "when State is defined",
253
+ "and State is an object",
254
+ "and Visible imported",
255
+ "and Visible is defined",
256
+ "and Visible is an object",
257
+ "then Visible contains yes"
223
258
  ],
224
259
  "status": "pass"
225
260
  },
226
261
  {
227
262
  "type": "Metadata",
228
- "spec": "Event",
263
+ "spec": "States",
229
264
  "definition": [
230
- "Given Metadata.EVENT Type.Metadata test",
231
- "and Event imported",
232
- "when Event is defined",
233
- "and Event is an object",
234
- "then Event.ON_PIN is defined"
265
+ "Metadata.States test",
266
+ "and State imported",
267
+ "when State is defined",
268
+ "and State is an object",
269
+ "and Visible imported",
270
+ "and Visible is defined",
271
+ "and Visible is an object",
272
+ "then Visible contains no"
235
273
  ],
236
274
  "status": "pass"
237
275
  },
238
276
  {
239
277
  "type": "Metadata",
240
- "spec": "Event",
278
+ "spec": "States",
241
279
  "definition": [
242
- "Given Metadata.EVENT Type.Metadata test",
243
- "and Event imported",
244
- "when Event is defined",
245
- "then Event is an object"
280
+ "Metadata.States test",
281
+ "and State imported",
282
+ "when State is defined",
283
+ "and State is an object",
284
+ "and Visible imported",
285
+ "and Visible is defined",
286
+ "then Visible is an object"
246
287
  ],
247
288
  "status": "pass"
248
289
  },
249
290
  {
250
291
  "type": "Metadata",
251
- "spec": "Event",
292
+ "spec": "States",
252
293
  "definition": [
253
- "Given Metadata.EVENT Type.Metadata test",
254
- "and Event imported",
255
- "then Event is defined"
294
+ "Metadata.States test",
295
+ "and State imported",
296
+ "when State is defined",
297
+ "and State is an object",
298
+ "and Status imported",
299
+ "and Status is defined",
300
+ "and Status is an object",
301
+ "then Status contains pinned"
256
302
  ],
257
303
  "status": "pass"
258
304
  },
259
305
  {
260
- "type": "Operation",
261
- "spec": "Show",
306
+ "type": "Metadata",
307
+ "spec": "States",
262
308
  "definition": [
263
- "Operation.Show test",
264
- "and Pin is defined in custom element registry",
265
- "and HTML Template is added to DOM",
266
- "and a new pin is added to DOM",
267
- "then pin.show() method is defined"
309
+ "Metadata.States test",
310
+ "and State imported",
311
+ "when State is defined",
312
+ "and State is an object",
313
+ "and Status imported",
314
+ "and Status is defined",
315
+ "and Status is an object",
316
+ "then Status contains unpinned"
268
317
  ],
269
318
  "status": "pass"
270
319
  },
271
320
  {
272
- "type": "Operation",
273
- "spec": "Show",
321
+ "type": "Metadata",
322
+ "spec": "States",
274
323
  "definition": [
275
- "Operation.Show test",
276
- "and Pin is defined in custom element registry",
277
- "and HTML Template is added to DOM",
278
- "and a new pin is added to DOM",
279
- "and pin.visible is Visible.NO",
280
- "when pin.show() is called",
281
- "then pin.visible is Visible.YES"
324
+ "Metadata.States test",
325
+ "and State imported",
326
+ "when State is defined",
327
+ "and State is an object",
328
+ "and Status imported",
329
+ "and Status is defined",
330
+ "then Status is an object"
282
331
  ],
283
332
  "status": "pass"
284
333
  },
285
334
  {
286
- "type": "State",
287
- "spec": "Visible",
335
+ "type": "Metadata",
336
+ "spec": "States",
288
337
  "definition": [
289
- "State.Visible test",
290
- "Given Pin is defined in custom element registry",
291
- "and a HTML Template is added to DOM",
292
- "and a new pin is added to DOM",
293
- "when visible attribute is set to Visible.NO",
294
- "then pin.visible is Visible.NO"
338
+ "Metadata.States test",
339
+ "and State imported",
340
+ "when State is defined",
341
+ "and State is an object",
342
+ "and Status imported",
343
+ "then Status is defined"
295
344
  ],
296
345
  "status": "pass"
297
346
  },
298
347
  {
299
- "type": "State",
300
- "spec": "Visible",
348
+ "type": "Metadata",
349
+ "spec": "States",
301
350
  "definition": [
302
- "State.Visible test",
303
- "Given Pin is defined in custom element registry",
304
- "and a HTML Template is added to DOM",
305
- "and a new pin is added to DOM",
306
- "when pin.visible is set to Visible.NO",
307
- "then visible attribute is set to Visible.NO"
351
+ "Metadata.States test",
352
+ "and State imported",
353
+ "then State is defined"
308
354
  ],
309
355
  "status": "pass"
310
356
  },
311
357
  {
312
358
  "type": "State",
313
- "spec": "Visible",
359
+ "spec": "status",
314
360
  "definition": [
315
- "State.Visible test",
361
+ "State.status test",
316
362
  "Given Pin is defined in custom element registry",
317
363
  "and a HTML Template is added to DOM",
318
364
  "and a new pin is added to DOM",
319
- "when pin.visible is set to Visible.NO",
320
- "then pin.visible is Visible.NO"
365
+ "then pin.status property is defined"
321
366
  ],
322
367
  "status": "pass"
323
368
  },
324
369
  {
325
370
  "type": "State",
326
- "spec": "Visible",
371
+ "spec": "status",
327
372
  "definition": [
328
- "State.Visible test",
373
+ "State.status test",
329
374
  "Given Pin is defined in custom element registry",
330
375
  "and a HTML Template is added to DOM",
331
376
  "and a new pin is added to DOM",
332
- "and pin.visible property is defined",
333
- "then pin.visible is Visible.YES"
377
+ "then status attribute is defined"
334
378
  ],
335
379
  "status": "pass"
336
380
  },
337
381
  {
338
382
  "type": "State",
339
- "spec": "Visible",
383
+ "spec": "status",
340
384
  "definition": [
341
- "State.Visible test",
385
+ "State.status test",
342
386
  "Given Pin is defined in custom element registry",
343
387
  "and a HTML Template is added to DOM",
344
388
  "and a new pin is added to DOM",
345
- "then pin.visible property is defined"
389
+ "and pin.status property is defined",
390
+ "then pin.status is Status.UNPINNED"
346
391
  ],
347
392
  "status": "pass"
348
393
  },
349
394
  {
350
- "type": "Operation",
351
- "spec": "Unpin",
395
+ "type": "State",
396
+ "spec": "status",
352
397
  "definition": [
353
- "Operation.Unpin test",
354
- "and Pin is defined in custom element registry",
355
- "and HTML Template is added to DOM",
398
+ "State.status test",
399
+ "Given Pin is defined in custom element registry",
400
+ "and a HTML Template is added to DOM",
356
401
  "and a new pin is added to DOM",
357
- "and pin.unpin() method is defined",
358
- "and pin.status is Status.PINNED",
359
- "when pin.unpin() is called",
360
- "then pin.status is Status.UNPINNED"
402
+ "when status attribute is set to Status.PINNED",
403
+ "then pin.status is Status.PINNED"
361
404
  ],
362
405
  "status": "pass"
363
406
  },
364
407
  {
365
- "type": "Operation",
366
- "spec": "Unpin",
408
+ "type": "State",
409
+ "spec": "status",
367
410
  "definition": [
368
- "Operation.Unpin test",
369
- "and Pin is defined in custom element registry",
370
- "and HTML Template is added to DOM",
411
+ "State.status test",
412
+ "Given Pin is defined in custom element registry",
413
+ "and a HTML Template is added to DOM",
371
414
  "and a new pin is added to DOM",
372
- "then pin.unpin() method is defined"
415
+ "and status attribute is defined",
416
+ "then status attribute is set to Status.UNPINNED"
373
417
  ],
374
418
  "status": "pass"
375
419
  },
376
420
  {
377
- "type": "configuration",
378
- "spec": "TAG",
421
+ "type": "State",
422
+ "spec": "status",
379
423
  "definition": [
380
- "Configuration.TAG test",
381
- "and Pin imported",
382
- "and Pin is defined",
383
- "and Pin.Tag static getter is defined",
384
- "then Pin.Tag is Tag"
424
+ "State.status test",
425
+ "Given Pin is defined in custom element registry",
426
+ "and a HTML Template is added to DOM",
427
+ "and a new pin is added to DOM",
428
+ "when pin.status is set to Status.PINNED",
429
+ "then pin.status is Status.PINNED"
385
430
  ],
386
431
  "status": "pass"
387
432
  },
388
433
  {
389
- "type": "configuration",
390
- "spec": "TAG",
434
+ "type": "State",
435
+ "spec": "status",
391
436
  "definition": [
392
- "Configuration.TAG test",
393
- "and Pin imported",
394
- "and Pin is defined",
395
- "then Pin.Tag static getter is defined"
437
+ "State.status test",
438
+ "Given Pin is defined in custom element registry",
439
+ "and a HTML Template is added to DOM",
440
+ "and a new pin is added to DOM",
441
+ "when pin.status is set to Status.PINNED",
442
+ "then status attribute is set to Status.PINNED"
396
443
  ],
397
444
  "status": "pass"
398
445
  },
399
446
  {
400
- "type": "configuration",
401
- "spec": "TAG",
447
+ "type": "Metadata",
448
+ "spec": "Gestures",
402
449
  "definition": [
403
- "Configuration.TAG test",
404
- "and Pin imported",
405
- "then Pin is defined"
450
+ "Metadata.Gestures test",
451
+ "and Gesture imported",
452
+ "when Gesture is defined",
453
+ "then Gesture is an object"
406
454
  ],
407
455
  "status": "pass"
408
456
  },
409
457
  {
410
458
  "type": "Metadata",
411
- "spec": "Gesture",
459
+ "spec": "Gestures",
412
460
  "definition": [
413
- "Given Metadata.GESTURE Type.Metadata test",
461
+ "Metadata.Gestures test",
414
462
  "and Gesture imported",
415
463
  "when Gesture is defined",
416
464
  "and Gesture is an object",
@@ -420,197 +468,219 @@
420
468
  },
421
469
  {
422
470
  "type": "Metadata",
423
- "spec": "Gesture",
471
+ "spec": "Gestures",
424
472
  "definition": [
425
- "Given Metadata.GESTURE Type.Metadata test",
473
+ "Metadata.Gestures test",
426
474
  "and Gesture imported",
427
- "when Gesture is defined",
428
- "then Gesture is an object"
475
+ "then Gesture is defined"
429
476
  ],
430
477
  "status": "pass"
431
478
  },
432
479
  {
433
- "type": "Metadata",
434
- "spec": "Gesture",
480
+ "type": "Event",
481
+ "spec": "onunpin",
435
482
  "definition": [
436
- "Given Metadata.GESTURE Type.Metadata test",
437
- "and Gesture imported",
438
- "then Gesture is defined"
483
+ "Event.onunpin test",
484
+ "and Pin is defined in custom element registry",
485
+ "and HTML Template is added to DOM",
486
+ "and a new pin is added to DOM",
487
+ "and pin.status is set to Status.PINNED",
488
+ "and pin.onunpin setter is defined",
489
+ "and pin.onunpin is set to new listener ",
490
+ "when pin.status set to Status.UNPINNED",
491
+ "then onunpin is not called"
439
492
  ],
440
493
  "status": "pass"
441
494
  },
442
495
  {
443
- "type": "Operation",
444
- "spec": "Toggle",
496
+ "type": "Event",
497
+ "spec": "onunpin",
445
498
  "definition": [
446
- "Operation.Toggle test",
499
+ "Event.onunpin test",
447
500
  "and Pin is defined in custom element registry",
448
501
  "and HTML Template is added to DOM",
449
502
  "and a new pin is added to DOM",
450
- "then pin.toggle() method is defined"
503
+ "and pin.status is set to Status.PINNED",
504
+ "and pin.onunpin setter is defined",
505
+ "and pin.onunpin is set to new listener ",
506
+ "when pin.status set to Status.UNPINNED",
507
+ "then onunpin2 is called"
451
508
  ],
452
509
  "status": "pass"
453
510
  },
454
511
  {
455
- "type": "Operation",
456
- "spec": "Toggle",
512
+ "type": "Event",
513
+ "spec": "onunpin",
457
514
  "definition": [
458
- "Operation.Toggle test",
515
+ "Event.onunpin test",
459
516
  "and Pin is defined in custom element registry",
460
517
  "and HTML Template is added to DOM",
461
518
  "and a new pin is added to DOM",
462
- "and pin.toggle() method is defined",
463
- "when pin.toggle() is called",
464
- "and pin.toggle() is called",
465
- "then pin.status is Status.UNPINNED"
519
+ "and pin.status is set to Status.PINNED",
520
+ "and pin.onunpin setter is defined",
521
+ "when pin.status set to Status.UNPINNED",
522
+ "then onunpin is called with `status: Status.UNPINNED`"
466
523
  ],
467
524
  "status": "pass"
468
525
  },
469
526
  {
470
- "type": "Operation",
471
- "spec": "Toggle",
527
+ "type": "Event",
528
+ "spec": "onunpin",
472
529
  "definition": [
473
- "Operation.Toggle test",
530
+ "Event.onunpin test",
474
531
  "and Pin is defined in custom element registry",
475
532
  "and HTML Template is added to DOM",
476
533
  "and a new pin is added to DOM",
477
- "and pin.toggle() method is defined",
478
- "when pin.toggle() is called",
479
- "then pin.status is Status.PINNED"
534
+ "then pin.onunpin setter is defined"
480
535
  ],
481
536
  "status": "pass"
482
537
  },
483
538
  {
484
- "type": "State",
485
- "spec": "Status",
539
+ "type": "Operation",
540
+ "spec": "toggle",
486
541
  "definition": [
487
- "State.Status test",
488
- "Given Pin is defined in custom element registry",
489
- "and a HTML Template is added to DOM",
542
+ "Operation.toggle test",
543
+ "and Pin is defined in custom element registry",
544
+ "and HTML Template is added to DOM",
490
545
  "and a new pin is added to DOM",
491
- "when pin.status is set to Status.PINNED",
492
- "then status attribute is set to Status.PINNED"
546
+ "then pin.toggle() method is defined"
493
547
  ],
494
548
  "status": "pass"
495
549
  },
496
550
  {
497
- "type": "State",
498
- "spec": "Status",
551
+ "type": "Operation",
552
+ "spec": "toggle",
499
553
  "definition": [
500
- "State.Status test",
501
- "Given Pin is defined in custom element registry",
502
- "and a HTML Template is added to DOM",
554
+ "Operation.toggle test",
555
+ "and Pin is defined in custom element registry",
556
+ "and HTML Template is added to DOM",
503
557
  "and a new pin is added to DOM",
504
- "when pin.status is set to Status.PINNED",
558
+ "and pin.toggle() method is defined",
559
+ "when pin.toggle() is called",
505
560
  "then pin.status is Status.PINNED"
506
561
  ],
507
562
  "status": "pass"
508
563
  },
509
564
  {
510
- "type": "State",
511
- "spec": "Status",
565
+ "type": "Operation",
566
+ "spec": "toggle",
512
567
  "definition": [
513
- "State.Status test",
514
- "Given Pin is defined in custom element registry",
515
- "and a HTML Template is added to DOM",
568
+ "Operation.toggle test",
569
+ "and Pin is defined in custom element registry",
570
+ "and HTML Template is added to DOM",
516
571
  "and a new pin is added to DOM",
517
- "and status attribute is defined",
518
- "then status attribute is set to Status.UNPINNED"
572
+ "and pin.toggle() method is defined",
573
+ "when pin.toggle() is called",
574
+ "and pin.toggle() is called",
575
+ "then pin.status is Status.UNPINNED"
519
576
  ],
520
577
  "status": "pass"
521
578
  },
522
579
  {
523
- "type": "State",
524
- "spec": "Status",
580
+ "type": "Operation",
581
+ "spec": "hide",
525
582
  "definition": [
526
- "State.Status test",
527
- "Given Pin is defined in custom element registry",
528
- "and a HTML Template is added to DOM",
583
+ "Operation.hide test",
584
+ "and Pin is defined in custom element registry",
585
+ "and HTML Template is added to DOM",
529
586
  "and a new pin is added to DOM",
530
- "and pin.status property is defined",
531
- "then pin.status is Status.UNPINNED"
587
+ "then pin.hide() method is defined"
532
588
  ],
533
589
  "status": "pass"
534
590
  },
535
591
  {
536
- "type": "State",
537
- "spec": "Status",
592
+ "type": "Operation",
593
+ "spec": "hide",
538
594
  "definition": [
539
- "State.Status test",
540
- "Given Pin is defined in custom element registry",
541
- "and a HTML Template is added to DOM",
595
+ "Operation.hide test",
596
+ "and Pin is defined in custom element registry",
597
+ "and HTML Template is added to DOM",
542
598
  "and a new pin is added to DOM",
543
- "then pin.status property is defined"
599
+ "and pin.hide() method is defined",
600
+ "when pin.hide() is called",
601
+ "then pin.visible is Visible.NO"
544
602
  ],
545
603
  "status": "pass"
546
604
  },
547
605
  {
548
- "type": "State",
549
- "spec": "Status",
606
+ "type": "Operation",
607
+ "spec": "pin",
550
608
  "definition": [
551
- "State.Status test",
552
- "Given Pin is defined in custom element registry",
553
- "and a HTML Template is added to DOM",
609
+ "Operation.pin test",
610
+ "and Pin is defined in custom element registry",
611
+ "and HTML Template is added to DOM",
554
612
  "and a new pin is added to DOM",
555
- "when status attribute is set to Status.PINNED",
556
- "then pin.status is Status.PINNED"
613
+ "then pin.pin() method is defined"
557
614
  ],
558
615
  "status": "pass"
559
616
  },
560
617
  {
561
- "type": "State",
562
- "spec": "Status",
618
+ "type": "Operation",
619
+ "spec": "pin",
563
620
  "definition": [
564
- "State.Status test",
565
- "Given Pin is defined in custom element registry",
566
- "and a HTML Template is added to DOM",
621
+ "Operation.pin test",
622
+ "and Pin is defined in custom element registry",
623
+ "and HTML Template is added to DOM",
567
624
  "and a new pin is added to DOM",
568
- "then status attribute is defined"
625
+ "and pin.pin() method is defined",
626
+ "when pin.pin() is called",
627
+ "then pin.status is Status.PINNED"
569
628
  ],
570
629
  "status": "pass"
571
630
  },
572
631
  {
573
- "type": "Metadata",
574
- "spec": "State",
632
+ "type": "Event",
633
+ "spec": "on",
575
634
  "definition": [
576
- "Given Metadata.STATE Type.Metadata test",
577
- "and State imported",
578
- "when State is defined",
579
- "and State is an object",
580
- "then State contains status"
635
+ "Event.on test",
636
+ "and Pin is defined in custom element registry",
637
+ "and HTML Template is added to DOM",
638
+ "and a new pin is added to DOM",
639
+ "and pin.on setter is defined",
640
+ "when pin.visible set to Visible.NO",
641
+ "then on is called with `visible: Visible.NO`"
581
642
  ],
582
643
  "status": "pass"
583
644
  },
584
645
  {
585
- "type": "Metadata",
586
- "spec": "State",
646
+ "type": "Event",
647
+ "spec": "on",
587
648
  "definition": [
588
- "Given Metadata.STATE Type.Metadata test",
589
- "and State imported",
590
- "when State is defined",
591
- "and State is an object",
592
- "then State contains visible"
649
+ "Event.on test",
650
+ "and Pin is defined in custom element registry",
651
+ "and HTML Template is added to DOM",
652
+ "and a new pin is added to DOM",
653
+ "and pin.on setter is defined",
654
+ "and pin.on is set to new listener ",
655
+ "when pin.visible set to Visible.NO",
656
+ "then on is not called"
593
657
  ],
594
658
  "status": "pass"
595
659
  },
596
660
  {
597
- "type": "Metadata",
598
- "spec": "State",
661
+ "type": "Event",
662
+ "spec": "on",
599
663
  "definition": [
600
- "Given Metadata.STATE Type.Metadata test",
601
- "and State imported",
602
- "when State is defined",
603
- "then State is an object"
664
+ "Event.on test",
665
+ "and Pin is defined in custom element registry",
666
+ "and HTML Template is added to DOM",
667
+ "and a new pin is added to DOM",
668
+ "and pin.on setter is defined",
669
+ "and pin.on is set to new listener ",
670
+ "when pin.visible set to Visible.NO",
671
+ "then on2 is called"
604
672
  ],
605
673
  "status": "pass"
606
674
  },
607
675
  {
608
- "type": "Metadata",
609
- "spec": "State",
676
+ "type": "Event",
677
+ "spec": "on",
610
678
  "definition": [
611
- "Given Metadata.STATE Type.Metadata test",
612
- "and State imported",
613
- "then State is defined"
679
+ "Event.on test",
680
+ "and Pin is defined in custom element registry",
681
+ "and HTML Template is added to DOM",
682
+ "and a new pin is added to DOM",
683
+ "then pin.on setter is defined"
614
684
  ],
615
685
  "status": "pass"
616
686
  },
@@ -631,8 +701,7 @@
631
701
  "Configuration.ATTRIBUTE test",
632
702
  "and Pin imported",
633
703
  "and Pin is defined",
634
- "and Pin.Attributes static getter is defined",
635
- "then Pin.Attributes is Attribute"
704
+ "then Pin.Attributes static getter is defined"
636
705
  ],
637
706
  "status": "pass"
638
707
  },
@@ -643,629 +712,584 @@
643
712
  "Configuration.ATTRIBUTE test",
644
713
  "and Pin imported",
645
714
  "and Pin is defined",
646
- "then Pin.Attributes static getter is defined"
715
+ "and Pin.Attributes static getter is defined",
716
+ "then Pin.Attributes is Attribute"
647
717
  ],
648
718
  "status": "pass"
649
719
  },
650
720
  {
651
- "type": "Metadata",
652
- "spec": "Operation",
721
+ "type": "State",
722
+ "spec": "visible",
653
723
  "definition": [
654
- "Given Metadata.OPERATION Type.Metadata test",
655
- "and Operation imported",
656
- "when Operation is defined",
657
- "and Operation is an object",
658
- "then Operation contains pin"
724
+ "State.visible test",
725
+ "Given Pin is defined in custom element registry",
726
+ "and a HTML Template is added to DOM",
727
+ "and a new pin is added to DOM",
728
+ "then pin.visible property is defined"
659
729
  ],
660
730
  "status": "pass"
661
731
  },
662
732
  {
663
- "type": "Metadata",
664
- "spec": "Operation",
733
+ "type": "State",
734
+ "spec": "visible",
665
735
  "definition": [
666
- "Given Metadata.OPERATION Type.Metadata test",
667
- "and Operation imported",
668
- "when Operation is defined",
669
- "and Operation is an object",
670
- "then Operation contains show"
736
+ "State.visible test",
737
+ "Given Pin is defined in custom element registry",
738
+ "and a HTML Template is added to DOM",
739
+ "and a new pin is added to DOM",
740
+ "and pin.visible property is defined",
741
+ "then pin.visible is Visible.YES"
671
742
  ],
672
743
  "status": "pass"
673
744
  },
674
745
  {
675
- "type": "Metadata",
676
- "spec": "Operation",
746
+ "type": "State",
747
+ "spec": "visible",
677
748
  "definition": [
678
- "Given Metadata.OPERATION Type.Metadata test",
679
- "and Operation imported",
680
- "when Operation is defined",
681
- "and Operation is an object",
682
- "then Operation contains toggle"
749
+ "State.visible test",
750
+ "Given Pin is defined in custom element registry",
751
+ "and a HTML Template is added to DOM",
752
+ "and a new pin is added to DOM",
753
+ "when visible attribute is set to Visible.NO",
754
+ "then pin.visible is Visible.NO"
683
755
  ],
684
756
  "status": "pass"
685
757
  },
686
758
  {
687
- "type": "Metadata",
688
- "spec": "Operation",
759
+ "type": "State",
760
+ "spec": "visible",
689
761
  "definition": [
690
- "Given Metadata.OPERATION Type.Metadata test",
691
- "and Operation imported",
692
- "when Operation is defined",
693
- "and Operation is an object",
694
- "then Operation contains hide"
762
+ "State.visible test",
763
+ "Given Pin is defined in custom element registry",
764
+ "and a HTML Template is added to DOM",
765
+ "and a new pin is added to DOM",
766
+ "when pin.visible is set to Visible.NO",
767
+ "then pin.visible is Visible.NO"
695
768
  ],
696
769
  "status": "pass"
697
770
  },
698
771
  {
699
- "type": "Metadata",
700
- "spec": "Operation",
772
+ "type": "State",
773
+ "spec": "visible",
701
774
  "definition": [
702
- "Given Metadata.OPERATION Type.Metadata test",
703
- "and Operation imported",
704
- "when Operation is defined",
705
- "and Operation is an object",
706
- "then Operation contains unpin"
775
+ "State.visible test",
776
+ "Given Pin is defined in custom element registry",
777
+ "and a HTML Template is added to DOM",
778
+ "and a new pin is added to DOM",
779
+ "when pin.visible is set to Visible.NO",
780
+ "then visible attribute is set to Visible.NO"
707
781
  ],
708
782
  "status": "pass"
709
783
  },
710
784
  {
711
785
  "type": "Metadata",
712
- "spec": "Operation",
786
+ "spec": "Events",
713
787
  "definition": [
714
- "Given Metadata.OPERATION Type.Metadata test",
715
- "and Operation imported",
716
- "when Operation is defined",
717
- "then Operation is an object"
788
+ "Metadata.Events test",
789
+ "and Event imported",
790
+ "when Event is defined",
791
+ "and Event is an object",
792
+ "then Event.ON is defined"
718
793
  ],
719
794
  "status": "pass"
720
795
  },
721
796
  {
722
797
  "type": "Metadata",
723
- "spec": "Operation",
798
+ "spec": "Events",
724
799
  "definition": [
725
- "Given Metadata.OPERATION Type.Metadata test",
726
- "and Operation imported",
727
- "then Operation is defined"
800
+ "Metadata.Events test",
801
+ "and Event imported",
802
+ "when Event is defined",
803
+ "and Event is an object",
804
+ "then Event.ON_PIN is defined"
728
805
  ],
729
806
  "status": "pass"
730
807
  },
731
808
  {
732
- "type": "Event",
733
- "spec": "ON_PIN",
809
+ "type": "Metadata",
810
+ "spec": "Events",
734
811
  "definition": [
735
- "Event.ON_PIN test",
736
- "and Pin is defined in custom element registry",
737
- "and HTML Template is added to DOM",
738
- "and a new pin is added to DOM",
739
- "and pin.onpin setter is defined",
740
- "and pin.onpin is set to new listener ",
741
- "when pin.status set to Status.PINNED",
742
- "then onpin2 is called"
812
+ "Metadata.Events test",
813
+ "and Event imported",
814
+ "when Event is defined",
815
+ "and Event is an object",
816
+ "then Event.ON_UNPIN is defined"
743
817
  ],
744
818
  "status": "pass"
745
819
  },
746
820
  {
747
- "type": "Event",
748
- "spec": "ON_PIN",
821
+ "type": "Metadata",
822
+ "spec": "Events",
749
823
  "definition": [
750
- "Event.ON_PIN test",
751
- "and Pin is defined in custom element registry",
752
- "and HTML Template is added to DOM",
753
- "and a new pin is added to DOM",
754
- "and pin.onpin setter is defined",
755
- "and pin.onpin is set to new listener ",
756
- "when pin.status set to Status.PINNED",
757
- "then onpin is not called"
824
+ "Metadata.Events test",
825
+ "and Event imported",
826
+ "when Event is defined",
827
+ "and Event is an object",
828
+ "then Event.ON_SHOW is defined"
758
829
  ],
759
830
  "status": "pass"
760
831
  },
761
832
  {
762
- "type": "Event",
763
- "spec": "ON_PIN",
833
+ "type": "Metadata",
834
+ "spec": "Events",
764
835
  "definition": [
765
- "Event.ON_PIN test",
766
- "and Pin is defined in custom element registry",
767
- "and HTML Template is added to DOM",
768
- "and a new pin is added to DOM",
769
- "and pin.onpin setter is defined",
770
- "when pin.status set to Status.PINNED",
771
- "then onpin is called with `status: Status.PINNED`"
836
+ "Metadata.Events test",
837
+ "and Event imported",
838
+ "when Event is defined",
839
+ "and Event is an object",
840
+ "then Event.ON_HIDE is defined"
772
841
  ],
773
842
  "status": "pass"
774
843
  },
775
844
  {
776
- "type": "Event",
777
- "spec": "ON_PIN",
845
+ "type": "Metadata",
846
+ "spec": "Events",
778
847
  "definition": [
779
- "Event.ON_PIN test",
780
- "and Pin is defined in custom element registry",
781
- "and HTML Template is added to DOM",
782
- "and a new pin is added to DOM",
783
- "then pin.onpin setter is defined"
848
+ "Metadata.Events test",
849
+ "and Event imported",
850
+ "when Event is defined",
851
+ "then Event is an object"
784
852
  ],
785
853
  "status": "pass"
786
854
  },
787
855
  {
788
- "type": "composition",
789
- "spec": "CSS",
856
+ "type": "Metadata",
857
+ "spec": "Events",
790
858
  "definition": [
791
- "Composition.CSS test",
792
- "Given Pin is defined in custom element registry",
793
- "and HTML Template is added to DOM",
794
- "and a new pin is added to DOM",
795
- "then pin.root contents contains a link to stylesheet"
859
+ "Metadata.Events test",
860
+ "and Event imported",
861
+ "then Event is defined"
796
862
  ],
797
863
  "status": "pass"
798
864
  },
799
865
  {
800
866
  "type": "Operation",
801
- "spec": "Hide",
867
+ "spec": "show",
802
868
  "definition": [
803
- "Operation.Hide test",
869
+ "Operation.show test",
804
870
  "and Pin is defined in custom element registry",
805
871
  "and HTML Template is added to DOM",
806
872
  "and a new pin is added to DOM",
807
- "and pin.hide() method is defined",
808
- "when pin.hide() is called",
809
- "then pin.visible is Visible.NO"
873
+ "then pin.show() method is defined"
810
874
  ],
811
875
  "status": "pass"
812
876
  },
813
877
  {
814
878
  "type": "Operation",
815
- "spec": "Hide",
879
+ "spec": "show",
816
880
  "definition": [
817
- "Operation.Hide test",
881
+ "Operation.show test",
818
882
  "and Pin is defined in custom element registry",
819
883
  "and HTML Template is added to DOM",
820
884
  "and a new pin is added to DOM",
821
- "then pin.hide() method is defined"
885
+ "and pin.visible is Visible.NO",
886
+ "when pin.show() is called",
887
+ "then pin.visible is Visible.YES"
822
888
  ],
823
889
  "status": "pass"
824
890
  },
825
891
  {
826
- "type": "Event",
827
- "spec": "ON_HIDE",
892
+ "type": "utility",
893
+ "spec": "GET",
828
894
  "definition": [
829
- "Event.ON_HIDE test",
830
- "and Pin is defined in custom element registry",
831
- "and HTML Template is added to DOM",
832
- "and a new pin is added to DOM",
833
- "and pin.onhide setter is defined",
834
- "and pin.onhide is set to new listener ",
835
- "when pin.visible set to Visible.NO",
836
- "then onhide is not called"
895
+ "Utility.GET test",
896
+ "then Pin.get static method is defined"
837
897
  ],
838
898
  "status": "pass"
839
899
  },
840
900
  {
841
- "type": "Event",
842
- "spec": "ON_HIDE",
901
+ "type": "utility",
902
+ "spec": "GET",
843
903
  "definition": [
844
- "Event.ON_HIDE test",
904
+ "Utility.GET test",
845
905
  "and Pin is defined in custom element registry",
846
- "and HTML Template is added to DOM",
906
+ "and the pin.template.html is added to the DOM",
847
907
  "and a new pin is added to DOM",
848
- "and pin.onhide setter is defined",
849
- "and pin.onhide is set to new listener ",
850
- "when pin.visible set to Visible.NO",
851
- "then onhide2 is called"
908
+ "when Pin.get() is called",
909
+ "then pins is an Pin"
852
910
  ],
853
911
  "status": "pass"
854
912
  },
855
913
  {
856
- "type": "Event",
857
- "spec": "ON_HIDE",
914
+ "type": "utility",
915
+ "spec": "GET",
858
916
  "definition": [
859
- "Event.ON_HIDE test",
917
+ "Utility.GET test",
860
918
  "and Pin is defined in custom element registry",
861
- "and HTML Template is added to DOM",
919
+ "and the pin.template.html is added to the DOM",
862
920
  "and a new pin is added to DOM",
863
- "and pin.onhide setter is defined",
864
- "when pin.visible set to Visible.NO",
865
- "then onhide is called with `visible: Visible.NO`"
921
+ "when Pin.get() is called",
922
+ "then items in array of pins match pins in DOM"
866
923
  ],
867
924
  "status": "pass"
868
925
  },
869
926
  {
870
- "type": "Event",
871
- "spec": "ON_HIDE",
927
+ "type": "utility",
928
+ "spec": "GET",
872
929
  "definition": [
873
- "Event.ON_HIDE test",
930
+ "Utility.GET test",
874
931
  "and Pin is defined in custom element registry",
875
- "and HTML Template is added to DOM",
932
+ "and the pin.template.html is added to the DOM",
876
933
  "and a new pin is added to DOM",
877
- "then pin.onhide setter is defined"
934
+ "when Pin.get() is called",
935
+ "then pins is defined"
878
936
  ],
879
937
  "status": "pass"
880
938
  },
881
939
  {
882
- "type": "Event",
883
- "spec": "ON",
940
+ "type": "Metadata",
941
+ "spec": "Tag",
884
942
  "definition": [
885
- "Event.ON test",
886
- "and Pin is defined in custom element registry",
887
- "and HTML Template is added to DOM",
888
- "and a new pin is added to DOM",
889
- "then pin.on setter is defined"
943
+ "Metadata.Tag test",
944
+ "when Tag imported",
945
+ "then Tag is defined"
890
946
  ],
891
947
  "status": "pass"
892
948
  },
893
949
  {
894
- "type": "Event",
895
- "spec": "ON",
950
+ "type": "Operation",
951
+ "spec": "unpin",
896
952
  "definition": [
897
- "Event.ON test",
953
+ "Operation.unpin test",
898
954
  "and Pin is defined in custom element registry",
899
955
  "and HTML Template is added to DOM",
900
956
  "and a new pin is added to DOM",
901
- "and pin.on setter is defined",
902
- "and pin.on is set to new listener ",
903
- "when pin.visible set to Visible.NO",
904
- "then on is not called"
957
+ "and pin.unpin() method is defined",
958
+ "and pin.status is Status.PINNED",
959
+ "when pin.unpin() is called",
960
+ "then pin.status is Status.UNPINNED"
905
961
  ],
906
962
  "status": "pass"
907
963
  },
908
964
  {
909
- "type": "Event",
910
- "spec": "ON",
965
+ "type": "Operation",
966
+ "spec": "unpin",
911
967
  "definition": [
912
- "Event.ON test",
968
+ "Operation.unpin test",
913
969
  "and Pin is defined in custom element registry",
914
970
  "and HTML Template is added to DOM",
915
971
  "and a new pin is added to DOM",
916
- "and pin.on setter is defined",
917
- "and pin.on is set to new listener ",
918
- "when pin.visible set to Visible.NO",
919
- "then on2 is called"
972
+ "then pin.unpin() method is defined"
920
973
  ],
921
974
  "status": "pass"
922
975
  },
923
976
  {
924
977
  "type": "Event",
925
- "spec": "ON",
978
+ "spec": "onhide",
926
979
  "definition": [
927
- "Event.ON test",
980
+ "Event.onhide test",
928
981
  "and Pin is defined in custom element registry",
929
982
  "and HTML Template is added to DOM",
930
983
  "and a new pin is added to DOM",
931
- "and pin.on setter is defined",
932
- "when pin.visible set to Visible.NO",
933
- "then on is called with `visible: Visible.NO`"
984
+ "then pin.onhide setter is defined"
934
985
  ],
935
986
  "status": "pass"
936
987
  },
937
988
  {
938
- "type": "utility",
939
- "spec": "GET",
989
+ "type": "Event",
990
+ "spec": "onhide",
940
991
  "definition": [
941
- "Utility.GET test",
992
+ "Event.onhide test",
942
993
  "and Pin is defined in custom element registry",
943
- "and the Pin.template.html is added to the DOM",
994
+ "and HTML Template is added to DOM",
944
995
  "and a new pin is added to DOM",
945
- "when Pin.get() is called",
946
- "then pins is an array"
996
+ "and pin.onhide setter is defined",
997
+ "and pin.onhide is set to new listener ",
998
+ "when pin.visible set to Visible.NO",
999
+ "then onhide is not called"
947
1000
  ],
948
1001
  "status": "pass"
949
1002
  },
950
1003
  {
951
- "type": "utility",
952
- "spec": "GET",
1004
+ "type": "Event",
1005
+ "spec": "onhide",
953
1006
  "definition": [
954
- "Utility.GET test",
1007
+ "Event.onhide test",
955
1008
  "and Pin is defined in custom element registry",
956
- "and the Pin.template.html is added to the DOM",
1009
+ "and HTML Template is added to DOM",
957
1010
  "and a new pin is added to DOM",
958
- "when Pin.get() is called",
959
- "then items in array of pins match pins in DOM"
1011
+ "and pin.onhide setter is defined",
1012
+ "and pin.onhide is set to new listener ",
1013
+ "when pin.visible set to Visible.NO",
1014
+ "then onhide2 is called"
960
1015
  ],
961
1016
  "status": "pass"
962
1017
  },
963
1018
  {
964
- "type": "utility",
965
- "spec": "GET",
1019
+ "type": "Event",
1020
+ "spec": "onhide",
966
1021
  "definition": [
967
- "Utility.GET test",
1022
+ "Event.onhide test",
968
1023
  "and Pin is defined in custom element registry",
969
- "and the Pin.template.html is added to the DOM",
1024
+ "and HTML Template is added to DOM",
970
1025
  "and a new pin is added to DOM",
971
- "when Pin.get() is called",
972
- "then pins is defined"
1026
+ "and pin.onhide setter is defined",
1027
+ "when pin.visible set to Visible.NO",
1028
+ "then onhide is called with `visible: Visible.NO`"
973
1029
  ],
974
1030
  "status": "pass"
975
1031
  },
976
1032
  {
977
- "type": "utility",
978
- "spec": "GET",
1033
+ "type": "Metadata",
1034
+ "spec": "Operations",
979
1035
  "definition": [
980
- "Utility.GET test",
981
- "then Pin.get static method is defined"
1036
+ "Metadata.Operations test",
1037
+ "and Operation imported",
1038
+ "when Operation is defined",
1039
+ "then Operation is an object"
982
1040
  ],
983
1041
  "status": "pass"
984
1042
  },
985
1043
  {
986
1044
  "type": "Metadata",
987
- "spec": "Attribute",
1045
+ "spec": "Operations",
988
1046
  "definition": [
989
- "Given Metadata.ATTRIBUTE Type.Metadata test",
990
- "and Attribute imported",
991
- "then Attribute is defined"
1047
+ "Metadata.Operations test",
1048
+ "and Operation imported",
1049
+ "when Operation is defined",
1050
+ "and Operation is an object",
1051
+ "then Operation contains unpin"
992
1052
  ],
993
1053
  "status": "pass"
994
1054
  },
995
1055
  {
996
1056
  "type": "Metadata",
997
- "spec": "Attribute",
1057
+ "spec": "Operations",
998
1058
  "definition": [
999
- "Given Metadata.ATTRIBUTE Type.Metadata test",
1000
- "and Attribute imported",
1001
- "when Attribute is defined",
1002
- "and Attribute is an object",
1003
- "then Attribute contains status"
1059
+ "Metadata.Operations test",
1060
+ "and Operation imported",
1061
+ "when Operation is defined",
1062
+ "and Operation is an object",
1063
+ "then Operation contains pin"
1004
1064
  ],
1005
1065
  "status": "pass"
1006
1066
  },
1007
1067
  {
1008
1068
  "type": "Metadata",
1009
- "spec": "Attribute",
1069
+ "spec": "Operations",
1010
1070
  "definition": [
1011
- "Given Metadata.ATTRIBUTE Type.Metadata test",
1012
- "and Attribute imported",
1013
- "when Attribute is defined",
1014
- "and Attribute is an object",
1015
- "then Attribute contains visible"
1071
+ "Metadata.Operations test",
1072
+ "and Operation imported",
1073
+ "when Operation is defined",
1074
+ "and Operation is an object",
1075
+ "then Operation contains hide"
1016
1076
  ],
1017
1077
  "status": "pass"
1018
1078
  },
1019
1079
  {
1020
1080
  "type": "Metadata",
1021
- "spec": "Attribute",
1081
+ "spec": "Operations",
1022
1082
  "definition": [
1023
- "Given Metadata.ATTRIBUTE Type.Metadata test",
1024
- "and Attribute imported",
1025
- "when Attribute is defined",
1026
- "then Attribute is an object"
1083
+ "Metadata.Operations test",
1084
+ "and Operation imported",
1085
+ "when Operation is defined",
1086
+ "and Operation is an object",
1087
+ "then Operation contains show"
1027
1088
  ],
1028
1089
  "status": "pass"
1029
1090
  },
1030
1091
  {
1031
1092
  "type": "Metadata",
1032
- "spec": "Tag",
1093
+ "spec": "Operations",
1033
1094
  "definition": [
1034
- "Given Metadata.Tag Type.Metadata test",
1035
- "when Tag imported",
1036
- "then Tag is defined"
1095
+ "Metadata.Operations test",
1096
+ "and Operation imported",
1097
+ "when Operation is defined",
1098
+ "and Operation is an object",
1099
+ "then Operation contains toggle"
1037
1100
  ],
1038
1101
  "status": "pass"
1039
1102
  },
1040
1103
  {
1041
- "type": "Event",
1042
- "spec": "ON_SHOW",
1104
+ "type": "Metadata",
1105
+ "spec": "Operations",
1043
1106
  "definition": [
1044
- "Event.ON_SHOW test",
1045
- "and Pin is defined in custom element registry",
1046
- "and HTML Template is added to DOM",
1047
- "and a new pin is added to DOM",
1048
- "then pin.onshow setter is defined"
1107
+ "Metadata.Operations test",
1108
+ "and Operation imported",
1109
+ "then Operation is defined"
1049
1110
  ],
1050
1111
  "status": "pass"
1051
1112
  },
1052
1113
  {
1053
- "type": "Event",
1054
- "spec": "ON_SHOW",
1114
+ "type": "utility",
1115
+ "spec": "TEMPLATE",
1055
1116
  "definition": [
1056
- "Event.ON_SHOW test",
1057
- "and Pin is defined in custom element registry",
1058
- "and HTML Template is added to DOM",
1059
- "and a new pin is added to DOM",
1060
- "and pin.visible is set to Visible.NO",
1061
- "and pin.onshow setter is defined",
1062
- "and pin.onshow is set to new listener ",
1063
- "when pin.visible set to Visible.YES",
1064
- "then onshow2 is called"
1117
+ "Utility.TEMPLATE test",
1118
+ "then Pin.Template static property is defined"
1065
1119
  ],
1066
1120
  "status": "pass"
1067
1121
  },
1068
1122
  {
1069
- "type": "Event",
1070
- "spec": "ON_SHOW",
1123
+ "type": "utility",
1124
+ "spec": "TEMPLATE",
1071
1125
  "definition": [
1072
- "Event.ON_SHOW test",
1073
- "and Pin is defined in custom element registry",
1074
- "and HTML Template is added to DOM",
1075
- "and a new pin is added to DOM",
1076
- "and pin.visible is set to Visible.NO",
1077
- "and pin.onshow setter is defined",
1078
- "and pin.onshow is set to new listener ",
1079
- "when pin.visible set to Visible.YES",
1080
- "then onshow is not called"
1126
+ "Utility.TEMPLATE test",
1127
+ "and Pin.Template static property is defined",
1128
+ "then Pin.Template is a Template"
1081
1129
  ],
1082
1130
  "status": "pass"
1083
1131
  },
1084
1132
  {
1085
- "type": "Event",
1086
- "spec": "ON_SHOW",
1133
+ "type": "configuration",
1134
+ "spec": "TAG",
1087
1135
  "definition": [
1088
- "Event.ON_SHOW test",
1089
- "and Pin is defined in custom element registry",
1090
- "and HTML Template is added to DOM",
1091
- "and a new pin is added to DOM",
1092
- "and pin.visible is set to Visible.NO",
1093
- "and pin.onshow setter is defined",
1094
- "when pin.visible set to Visible.YES",
1095
- "then onshow is called with `visible: Visible.YES`"
1136
+ "Configuration.TAG test",
1137
+ "and Pin imported",
1138
+ "and Pin is defined",
1139
+ "and Pin.Tag static getter is defined",
1140
+ "then Pin.Tag is Tag"
1096
1141
  ],
1097
1142
  "status": "pass"
1098
1143
  },
1099
1144
  {
1100
- "type": "Event",
1101
- "spec": "ON_SHOW",
1145
+ "type": "configuration",
1146
+ "spec": "TAG",
1102
1147
  "definition": [
1103
- "Event.ON_SHOW test",
1104
- "and Pin is defined in custom element registry",
1105
- "and HTML Template is added to DOM",
1106
- "and a new pin is added to DOM",
1107
- "and pin.visible is set to Visible.NO",
1108
- "and pin.onshow setter is defined",
1109
- "when pin.visible set to Visible.YES",
1110
- "then onshow is called"
1148
+ "Configuration.TAG test",
1149
+ "and Pin imported",
1150
+ "and Pin is defined",
1151
+ "then Pin.Tag static getter is defined"
1111
1152
  ],
1112
1153
  "status": "pass"
1113
1154
  },
1114
1155
  {
1115
- "type": "Operation",
1116
- "spec": "Pin",
1156
+ "type": "configuration",
1157
+ "spec": "TAG",
1117
1158
  "definition": [
1118
- "Operation.Pin test",
1119
- "and Pin is defined in custom element registry",
1120
- "and HTML Template is added to DOM",
1121
- "and a new pin is added to DOM",
1122
- "and pin.pin() method is defined",
1123
- "when pin.pin() is called",
1124
- "then pin.status is Status.PINNED"
1159
+ "Configuration.TAG test",
1160
+ "and Pin imported",
1161
+ "then Pin is defined"
1125
1162
  ],
1126
1163
  "status": "pass"
1127
1164
  },
1128
1165
  {
1129
- "type": "Operation",
1130
- "spec": "Pin",
1166
+ "type": "composition",
1167
+ "spec": "Template",
1131
1168
  "definition": [
1132
- "Operation.Pin test",
1133
- "and Pin is defined in custom element registry",
1169
+ "Composition.Template test",
1170
+ "Given Pin is defined in custom element registry",
1134
1171
  "and HTML Template is added to DOM",
1135
- "and a new pin is added to DOM",
1136
- "then pin.pin() method is defined"
1172
+ "and template is defined",
1173
+ "and template contains div with class `icon`",
1174
+ "then div with class `icon` contain svg with class `unpinned`"
1137
1175
  ],
1138
1176
  "status": "pass"
1139
1177
  },
1140
1178
  {
1141
- "type": "utility",
1142
- "spec": "TEMPLATE",
1179
+ "type": "composition",
1180
+ "spec": "Template",
1143
1181
  "definition": [
1144
- "Utility.TEMPLATE test",
1145
- "and Pin.Template static property is defined",
1146
- "then Pin.Template is a Template"
1182
+ "Composition.Template test",
1183
+ "Given Pin is defined in custom element registry",
1184
+ "and HTML Template is added to DOM",
1185
+ "and template is defined",
1186
+ "and template contains div with class `icon`",
1187
+ "then div with class `icon` contain svg with class `pinned`"
1147
1188
  ],
1148
1189
  "status": "pass"
1149
1190
  },
1150
1191
  {
1151
- "type": "utility",
1152
- "spec": "TEMPLATE",
1192
+ "type": "composition",
1193
+ "spec": "Template",
1153
1194
  "definition": [
1154
- "Utility.TEMPLATE test",
1155
- "then Pin.Template static property is defined"
1195
+ "Composition.Template test",
1196
+ "Given Pin is defined in custom element registry",
1197
+ "and HTML Template is added to DOM",
1198
+ "and template is defined",
1199
+ "then template contains div with class `icon`"
1156
1200
  ],
1157
1201
  "status": "pass"
1158
1202
  },
1159
1203
  {
1160
- "type": "Event",
1161
- "spec": "ON_UNPIN",
1204
+ "type": "composition",
1205
+ "spec": "Template",
1162
1206
  "definition": [
1163
- "Event.ON_UNPIN test",
1164
- "and Pin is defined in custom element registry",
1207
+ "Composition.Template test",
1208
+ "Given Pin is defined in custom element registry",
1165
1209
  "and HTML Template is added to DOM",
1166
- "and a new pin is added to DOM",
1167
- "and pin.status is set to Status.PINNED",
1168
- "and pin.onunpin setter is defined",
1169
- "when pin.status set to Status.UNPINNED",
1170
- "then onunpin is called with `status: Status.UNPINNED`"
1210
+ "then template is defined"
1171
1211
  ],
1172
1212
  "status": "pass"
1173
1213
  },
1174
1214
  {
1175
- "type": "Event",
1176
- "spec": "ON_UNPIN",
1215
+ "type": "composition",
1216
+ "spec": "Template",
1177
1217
  "definition": [
1178
- "Event.ON_UNPIN test",
1179
- "and Pin is defined in custom element registry",
1218
+ "Composition.Template test",
1219
+ "Given Pin is defined in custom element registry",
1180
1220
  "and HTML Template is added to DOM",
1181
1221
  "and a new pin is added to DOM",
1182
- "and pin.status is set to Status.PINNED",
1183
- "and pin.onunpin setter is defined",
1184
- "and pin.onunpin is set to new listener ",
1185
- "when pin.status set to Status.UNPINNED",
1186
- "then onunpin2 is called"
1222
+ "then pin.root contents contains template contents"
1187
1223
  ],
1188
1224
  "status": "pass"
1189
1225
  },
1190
1226
  {
1191
- "type": "Event",
1192
- "spec": "ON_UNPIN",
1227
+ "type": "composition",
1228
+ "spec": "Template",
1193
1229
  "definition": [
1194
- "Event.ON_UNPIN test",
1195
- "and Pin is defined in custom element registry",
1230
+ "Composition.Template test",
1231
+ "Given Pin is defined in custom element registry",
1196
1232
  "and HTML Template is added to DOM",
1197
1233
  "and a new pin is added to DOM",
1198
- "and pin.status is set to Status.PINNED",
1199
- "and pin.onunpin setter is defined",
1200
- "and pin.onunpin is set to new listener ",
1201
- "when pin.status set to Status.UNPINNED",
1202
- "then onunpin is not called"
1234
+ "then pin.elements.icon is defined"
1203
1235
  ],
1204
1236
  "status": "pass"
1205
1237
  },
1206
1238
  {
1207
- "type": "Event",
1208
- "spec": "ON_UNPIN",
1239
+ "type": "composition",
1240
+ "spec": "Template",
1209
1241
  "definition": [
1210
- "Event.ON_UNPIN test",
1211
- "and Pin is defined in custom element registry",
1242
+ "Composition.Template test",
1243
+ "Given Pin is defined in custom element registry",
1212
1244
  "and HTML Template is added to DOM",
1213
1245
  "and a new pin is added to DOM",
1214
- "then pin.onunpin setter is defined"
1246
+ "and pin.elements.icon is defined",
1247
+ "then pin.elements.icon is an HTMLDivElement"
1215
1248
  ],
1216
1249
  "status": "pass"
1217
1250
  },
1218
1251
  {
1219
- "type": "Gesture",
1220
- "spec": "CLICK",
1252
+ "type": "Metadata",
1253
+ "spec": "Attributes",
1221
1254
  "definition": [
1222
- "Gesture.CLICK test",
1223
- "and Pin is defined in custom element registry",
1224
- "and HTML Template is added to DOM",
1225
- "and a new pin is added to DOM",
1226
- "when user click on icon",
1227
- "and user clicks on pin",
1228
- "then onunpin is called"
1255
+ "Metadata.Attributes test",
1256
+ "and Attribute imported",
1257
+ "then Attributes is defined"
1229
1258
  ],
1230
1259
  "status": "pass"
1231
1260
  },
1232
1261
  {
1233
- "type": "Gesture",
1234
- "spec": "CLICK",
1262
+ "type": "Metadata",
1263
+ "spec": "Attributes",
1235
1264
  "definition": [
1236
- "Gesture.CLICK test",
1237
- "and Pin is defined in custom element registry",
1238
- "and HTML Template is added to DOM",
1239
- "and a new pin is added to DOM",
1240
- "when user click on icon",
1241
- "and user clicks on pin",
1242
- "then pin.status is Status.UNPINNED"
1265
+ "Metadata.Attributes test",
1266
+ "and Attribute imported",
1267
+ "when Attributes is defined",
1268
+ "and Attributes is an object",
1269
+ "then Attributes contains visible"
1243
1270
  ],
1244
1271
  "status": "pass"
1245
1272
  },
1246
1273
  {
1247
- "type": "Gesture",
1248
- "spec": "CLICK",
1274
+ "type": "Metadata",
1275
+ "spec": "Attributes",
1249
1276
  "definition": [
1250
- "Gesture.CLICK test",
1251
- "and Pin is defined in custom element registry",
1252
- "and HTML Template is added to DOM",
1253
- "and a new pin is added to DOM",
1254
- "when user click on icon",
1255
- "then onpin is called"
1277
+ "Metadata.Attributes test",
1278
+ "and Attribute imported",
1279
+ "when Attributes is defined",
1280
+ "and Attributes is an object",
1281
+ "then Attributes contains status"
1256
1282
  ],
1257
1283
  "status": "pass"
1258
1284
  },
1259
1285
  {
1260
- "type": "Gesture",
1261
- "spec": "CLICK",
1286
+ "type": "Metadata",
1287
+ "spec": "Attributes",
1262
1288
  "definition": [
1263
- "Gesture.CLICK test",
1264
- "and Pin is defined in custom element registry",
1265
- "and HTML Template is added to DOM",
1266
- "and a new pin is added to DOM",
1267
- "when user click on icon",
1268
- "then pin.status is State.PINNED"
1289
+ "Metadata.Attributes test",
1290
+ "and Attribute imported",
1291
+ "when Attributes is defined",
1292
+ "then Attributes is an object"
1269
1293
  ],
1270
1294
  "status": "pass"
1271
1295
  }