On ToT, event.dataTransfer.getData("text/uri-list") returns an empty string when...
[WebKit-https.git] / LayoutTests / editing / pasteboard / data-transfer-item-list-add-file-multiple-times-expected.txt
1 Copy this text!
2 To manually test, copy the above text. The output below dumps DataTransfer state following each operation,
3
4 described directly above the output text for each step. The DataTransfer state should be consistent with the
5
6 operation performed at each step.
7
8
9 1. After adding all items
10 {
11     "data": {
12         "Files": "",
13         "text/uri-list": "https://webkit.org"
14     },
15     "items": [
16         {
17             "type": "text/plain",
18             "kind": "file",
19             "file": {
20                 "name": "file.txt",
21                 "bytes": 20,
22                 "type": "text/plain"
23             }
24         },
25         {
26             "type": "text/plain",
27             "kind": "file",
28             "file": {
29                 "name": "file.txt",
30                 "bytes": 20,
31                 "type": "text/plain"
32             }
33         },
34         {
35             "type": "text/plain",
36             "kind": "string",
37             "file": null
38         },
39         {
40             "type": "text/uri-list",
41             "kind": "string",
42             "file": null
43         },
44         {
45             "type": "text/plain",
46             "kind": "file",
47             "file": {
48                 "name": "file.txt",
49                 "bytes": 20,
50                 "type": "text/plain"
51             }
52         },
53         {
54             "type": "text/plain",
55             "kind": "file",
56             "file": {
57                 "name": "file.txt",
58                 "bytes": 20,
59                 "type": "text/plain"
60             }
61         }
62     ],
63     "files": [
64         {
65             "name": "file.txt",
66             "bytes": 20,
67             "type": "text/plain"
68         },
69         {
70             "name": "file.txt",
71             "bytes": 20,
72             "type": "text/plain"
73         },
74         {
75             "name": "file.txt",
76             "bytes": 20,
77             "type": "text/plain"
78         },
79         {
80             "name": "file.txt",
81             "bytes": 20,
82             "type": "text/plain"
83         }
84     ]
85 }
86
87 2. After removing at index 4
88 {
89     "data": {
90         "Files": "",
91         "text/uri-list": "https://webkit.org"
92     },
93     "items": [
94         {
95             "type": "text/plain",
96             "kind": "file",
97             "file": {
98                 "name": "file.txt",
99                 "bytes": 20,
100                 "type": "text/plain"
101             }
102         },
103         {
104             "type": "text/plain",
105             "kind": "file",
106             "file": {
107                 "name": "file.txt",
108                 "bytes": 20,
109                 "type": "text/plain"
110             }
111         },
112         {
113             "type": "text/plain",
114             "kind": "string",
115             "file": null
116         },
117         {
118             "type": "text/uri-list",
119             "kind": "string",
120             "file": null
121         },
122         {
123             "type": "text/plain",
124             "kind": "file",
125             "file": {
126                 "name": "file.txt",
127                 "bytes": 20,
128                 "type": "text/plain"
129             }
130         }
131     ],
132     "files": [
133         {
134             "name": "file.txt",
135             "bytes": 20,
136             "type": "text/plain"
137         },
138         {
139             "name": "file.txt",
140             "bytes": 20,
141             "type": "text/plain"
142         },
143         {
144             "name": "file.txt",
145             "bytes": 20,
146             "type": "text/plain"
147         }
148     ]
149 }
150 removedItem.getAsFile() should be null: null
151
152 3. After removing at index 1
153 {
154     "data": {
155         "Files": "",
156         "text/uri-list": "https://webkit.org"
157     },
158     "items": [
159         {
160             "type": "text/plain",
161             "kind": "file",
162             "file": {
163                 "name": "file.txt",
164                 "bytes": 20,
165                 "type": "text/plain"
166             }
167         },
168         {
169             "type": "text/plain",
170             "kind": "string",
171             "file": null
172         },
173         {
174             "type": "text/uri-list",
175             "kind": "string",
176             "file": null
177         },
178         {
179             "type": "text/plain",
180             "kind": "file",
181             "file": {
182                 "name": "file.txt",
183                 "bytes": 20,
184                 "type": "text/plain"
185             }
186         }
187     ],
188     "files": [
189         {
190             "name": "file.txt",
191             "bytes": 20,
192             "type": "text/plain"
193         },
194         {
195             "name": "file.txt",
196             "bytes": 20,
197             "type": "text/plain"
198         }
199     ]
200 }
201 removedItem.getAsFile() should be null: null
202
203 4. After removing at index 3
204 {
205     "data": {
206         "Files": "",
207         "text/uri-list": "https://webkit.org"
208     },
209     "items": [
210         {
211             "type": "text/plain",
212             "kind": "file",
213             "file": {
214                 "name": "file.txt",
215                 "bytes": 20,
216                 "type": "text/plain"
217             }
218         },
219         {
220             "type": "text/plain",
221             "kind": "string",
222             "file": null
223         },
224         {
225             "type": "text/uri-list",
226             "kind": "string",
227             "file": null
228         }
229     ],
230     "files": [
231         {
232             "name": "file.txt",
233             "bytes": 20,
234             "type": "text/plain"
235         }
236     ]
237 }
238 removedItem.getAsFile() should be null: null
239
240 5. After clearing items
241 {
242     "data": {},
243     "items": [],
244     "files": []
245 }
246
247 6. After adding two files and some string data again
248 {
249     "data": {
250         "Files": ""
251     },
252     "items": [
253         {
254             "type": "text/plain",
255             "kind": "file",
256             "file": {
257                 "name": "file.txt",
258                 "bytes": 20,
259                 "type": "text/plain"
260             }
261         },
262         {
263             "type": "text/html",
264             "kind": "string",
265             "file": null
266         },
267         {
268             "type": "text/plain",
269             "kind": "string",
270             "file": null
271         },
272         {
273             "type": "text/plain",
274             "kind": "file",
275             "file": {
276                 "name": "file.txt",
277                 "bytes": 20,
278                 "type": "text/plain"
279             }
280         }
281     ],
282     "files": [
283         {
284             "name": "file.txt",
285             "bytes": 20,
286             "type": "text/plain"
287         },
288         {
289             "name": "file.txt",
290             "bytes": 20,
291             "type": "text/plain"
292         }
293     ]
294 }
295
296 7. After removing at index 2
297 {
298     "data": {
299         "Files": ""
300     },
301     "items": [
302         {
303             "type": "text/plain",
304             "kind": "file",
305             "file": {
306                 "name": "file.txt",
307                 "bytes": 20,
308                 "type": "text/plain"
309             }
310         },
311         {
312             "type": "text/html",
313             "kind": "string",
314             "file": null
315         },
316         {
317             "type": "text/plain",
318             "kind": "file",
319             "file": {
320                 "name": "file.txt",
321                 "bytes": 20,
322                 "type": "text/plain"
323             }
324         }
325     ],
326     "files": [
327         {
328             "name": "file.txt",
329             "bytes": 20,
330             "type": "text/plain"
331         },
332         {
333             "name": "file.txt",
334             "bytes": 20,
335             "type": "text/plain"
336         }
337     ]
338 }
339 removedItem.getAsFile() should be null: null
340
341 8. After removing at index 2
342 {
343     "data": {
344         "Files": ""
345     },
346     "items": [
347         {
348             "type": "text/plain",
349             "kind": "file",
350             "file": {
351                 "name": "file.txt",
352                 "bytes": 20,
353                 "type": "text/plain"
354             }
355         },
356         {
357             "type": "text/html",
358             "kind": "string",
359             "file": null
360         }
361     ],
362     "files": [
363         {
364             "name": "file.txt",
365             "bytes": 20,
366             "type": "text/plain"
367         }
368     ]
369 }
370 removedItem.getAsFile() should be null: null
371
372 9. After removing at index 1
373 {
374     "data": {
375         "Files": ""
376     },
377     "items": [
378         {
379             "type": "text/plain",
380             "kind": "file",
381             "file": {
382                 "name": "file.txt",
383                 "bytes": 20,
384                 "type": "text/plain"
385             }
386         }
387     ],
388     "files": [
389         {
390             "name": "file.txt",
391             "bytes": 20,
392             "type": "text/plain"
393         }
394     ]
395 }
396 removedItem.getAsFile() should be null: null
397
398 10. After removing at index 0
399 {
400     "data": {},
401     "items": [],
402     "files": []
403 }
404 removedItem.getAsFile() should be null: null
405