Title: [118787] trunk/LayoutTests
- Revision
- 118787
- Author
- [email protected]
- Date
- 2012-05-29 09:17:54 -0700 (Tue, 29 May 2012)
Log Message
[FileAPI] Miss FileList test
https://bugs.webkit.org/show_bug.cgi?id=87696
Patch by Li Yin <[email protected]> on 2012-05-29
Reviewed by Kentaro Hara.
WebKit should have the test to track the attribute of FileList.
* fast/files/file-list-test-expected.txt: Added.
* fast/files/file-list-test.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (118786 => 118787)
--- trunk/LayoutTests/ChangeLog 2012-05-29 16:09:46 UTC (rev 118786)
+++ trunk/LayoutTests/ChangeLog 2012-05-29 16:17:54 UTC (rev 118787)
@@ -1,3 +1,15 @@
+2012-05-29 Li Yin <[email protected]>
+
+ [FileAPI] Miss FileList test
+ https://bugs.webkit.org/show_bug.cgi?id=87696
+
+ Reviewed by Kentaro Hara.
+
+ WebKit should have the test to track the attribute of FileList.
+
+ * fast/files/file-list-test-expected.txt: Added.
+ * fast/files/file-list-test.html: Added.
+
2012-05-29 Jessie Berlin <[email protected]>
[Mac] fast/events/message-port-constructor-for-deleted-document.html ASSERTS in Debug.
Added: trunk/LayoutTests/fast/files/file-list-test-expected.txt (0 => 118787)
--- trunk/LayoutTests/fast/files/file-list-test-expected.txt (rev 0)
+++ trunk/LayoutTests/fast/files/file-list-test-expected.txt 2012-05-29 16:17:54 UTC (rev 118787)
@@ -0,0 +1,16 @@
+
+Test the attribute of FileList.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+Start
+PASS files.length is 2
+PASS files.item(0) instanceof File is true
+PASS files.item(0).name is "UTF8.txt"
+PASS files.item(1) instanceof File is true
+PASS files.item(1).name is "UTF8-2.txt"
+PASS files.item(999) is null
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Added: trunk/LayoutTests/fast/files/file-list-test.html (0 => 118787)
--- trunk/LayoutTests/fast/files/file-list-test.html (rev 0)
+++ trunk/LayoutTests/fast/files/file-list-test.html 2012-05-29 16:17:54 UTC (rev 118787)
@@ -0,0 +1,32 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+</head>
+<body>
+<input type="file" multiple _onchange_="onInputFileChange(this.files)">
+<div id="description"></div>
+<div id="console"></div>
+<script>
+description("Test the attribute of FileList.");
+
+function onInputFileChange(files)
+{
+ window.files = files;
+ debug("Start");
+ shouldBe("files.length", "2");
+ shouldBeTrue("files.item(0) instanceof File");
+ shouldBeEqualToString('files.item(0).name', 'UTF8.txt');
+ shouldBeTrue("files.item(1) instanceof File");
+ shouldBeEqualToString('files.item(1).name', 'UTF8-2.txt');
+ shouldBeNull("files.item(999)");
+}
+
+eventSender.beginDragWithFiles(['resources/UTF8.txt', 'resources/UTF8-2.txt']);
+eventSender.mouseMoveTo(10, 10);
+eventSender.mouseUp();
+
+</script>
+</body>
+<script src=""
+</html>
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes