summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests
diff options
context:
space:
mode:
authorkinuko@chromium.org <kinuko@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2013-08-22 16:03:28 +0000
committerkinuko@chromium.org <kinuko@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2013-08-22 16:03:28 +0000
commita82b603ad588b1be00b7f1d3365af1caa425f9bb (patch)
treef0ab2ab636e8305b5a844625684352048c042156 /third_party/WebKit/LayoutTests
parent449f42d4ba65e02daa080be994b44a43713b5b7b (diff)
downloadchromium_src-a82b603ad588b1be00b7f1d3365af1caa425f9bb.zip
chromium_src-a82b603ad588b1be00b7f1d3365af1caa425f9bb.tar.gz
chromium_src-a82b603ad588b1be00b7f1d3365af1caa425f9bb.tar.bz2
Deprecate FileError in FileAPI
Apps should expect DOMError instead. This change breaks existing apps, so I kept FileError in this CL but made it inherit from DOMError and marked '.code' attribute deprecated. BUG=276861 TEST=fast/files/*,fast/filesystem/* Review URL: https://chromiumcodereview.appspot.com/22831019 git-svn-id: svn://svn.chromium.org/blink/trunk@156562 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Diffstat (limited to 'third_party/WebKit/LayoutTests')
-rw-r--r--third_party/WebKit/LayoutTests/TestExpectations3
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/file-reader-abort-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/file-reader-abort.html2
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/read-file-async-expected.txt10
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/resources/read-common.js18
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/workers/worker-read-blob-sync-expected.txt38
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-async-expected.txt10
-rw-r--r--third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-sync-expected.txt48
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/cross-filesystem-op.html2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/file-after-reload-crash.html2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/file-metadata-after-write.html2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/not-enough-arguments.html2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-copy-expected.txt20
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-get-entry-expected.txt20
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-get-metadata-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-move-expected.txt20
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-remove-expected.txt6
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-chars-expected.txt6
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-names-expected.txt4
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-unicode-expected.txt2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/async-operations.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/directory-entry-to-uri.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/file-entry-to-uri.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/file-from-file-entry.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/file-writer-abort.js4
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-copy.js20
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-entry.js24
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-metadata.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-move.js20
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-remove.js6
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-chars.js6
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-names.js4
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-unicode.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/op-tests-helper.js70
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-persistent.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getdirectory.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getfile.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getmetadata.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-remove.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-temporary.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-reference.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-unserializable.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/script-tests/read-directory.js2
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/simple-readonly-file-object.html2
-rw-r--r--third_party/WebKit/LayoutTests/http/tests/filesystem/resolve-uri-expected.txt14
-rw-r--r--third_party/WebKit/LayoutTests/http/tests/filesystem/script-tests/resolve-uri.js14
-rw-r--r--third_party/WebKit/LayoutTests/http/tests/filesystem/workers/resolve-url-expected.txt14
48 files changed, 226 insertions, 223 deletions
diff --git a/third_party/WebKit/LayoutTests/TestExpectations b/third_party/WebKit/LayoutTests/TestExpectations
index 84fb347..5d1d71a 100644
--- a/third_party/WebKit/LayoutTests/TestExpectations
+++ b/third_party/WebKit/LayoutTests/TestExpectations
@@ -1244,3 +1244,6 @@ crbug.com/277043 [ Mac ] fast/dom/adopt-node-crash-2.html [ Pass Failure ]
# Rebase once v8 i18n rolled.
Bug(jochen) fast/js/kde/inbuilt_function_tostring.html [ Pass Failure ]
+
+# Temporary, cannot reproduce on local win.
+crbug.com/276861 [ Win ] fast/filesystem/op-restricted-unicode.html [ Failure Pass ]
diff --git a/third_party/WebKit/LayoutTests/fast/files/file-reader-abort-expected.txt b/third_party/WebKit/LayoutTests/fast/files/file-reader-abort-expected.txt
index 2651ca8..98d62e7 100644
--- a/third_party/WebKit/LayoutTests/fast/files/file-reader-abort-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/files/file-reader-abort-expected.txt
@@ -1,7 +1,7 @@
Test that FileReader.abort works.
Received loadstart event
-Received error event: 3
+Received error event: AbortError
Received abort event
Received loadend event
DONE
diff --git a/third_party/WebKit/LayoutTests/fast/files/file-reader-abort.html b/third_party/WebKit/LayoutTests/fast/files/file-reader-abort.html
index 4da639c..cefca71 100644
--- a/third_party/WebKit/LayoutTests/fast/files/file-reader-abort.html
+++ b/third_party/WebKit/LayoutTests/fast/files/file-reader-abort.html
@@ -34,7 +34,7 @@ function onInputFileChange()
log("Received abort event");
};
reader.onerror = function(event) {
- log("Received error event: " + event.target.error.code);
+ log("Received error event: " + event.target.error.name);
};
}
diff --git a/third_party/WebKit/LayoutTests/fast/files/read-file-async-expected.txt b/third_party/WebKit/LayoutTests/fast/files/read-file-async-expected.txt
index ba2d0c8..2e850c9 100644
--- a/third_party/WebKit/LayoutTests/fast/files/read-file-async-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/files/read-file-async-expected.txt
@@ -3,28 +3,28 @@ Test reading a non-existent file as array buffer
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as binary string
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as text
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as data URL
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading an empty file as array buffer
@@ -207,7 +207,7 @@ Test reading again after failed read
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
readyState after recalling read method: 1
diff --git a/third_party/WebKit/LayoutTests/fast/files/resources/read-common.js b/third_party/WebKit/LayoutTests/fast/files/resources/read-common.js
index 98c3d54..bd9182c 100644
--- a/third_party/WebKit/LayoutTests/fast/files/resources/read-common.js
+++ b/third_party/WebKit/LayoutTests/fast/files/resources/read-common.js
@@ -74,14 +74,14 @@ function _readBlobAsArrayBufferSync(testFiles, blob)
var result = reader.readAsArrayBuffer(blob);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
try {
var result = reader.readAsArrayBuffer(12345);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
runNextTest(testFiles);
@@ -94,14 +94,14 @@ function _readBlobAsBinaryStringSync(testFiles, blob)
var result = reader.readAsBinaryString(blob);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
try {
var result = reader.readAsBinaryString(12345);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
runNextTest(testFiles);
@@ -114,14 +114,14 @@ function _readBlobAsTextSync(testFiles, blob, encoding)
var result = reader.readAsText(blob, encoding);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
try {
var result = reader.readAsText(12345, encoding);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
runNextTest(testFiles);
@@ -134,14 +134,14 @@ function _readBlobAsDataURLSync(testFiles, blob)
var result = reader.readAsDataURL(blob);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
try {
var result = reader.readAsDataURL(12345);
logResult(result);
} catch (error) {
- log("Received exception, code: " + error.code + ", name: " + error.name + ", message: " + error.message);
+ log("Received exception, name: " + error.name + ", message: " + error.message);
}
runNextTest(testFiles);
@@ -209,7 +209,7 @@ function loadFailed(event)
{
logEvent(event);
log("readyState: " + event.target.readyState);
- log("error code: " + event.target.error.code);
+ log("error name: " + event.target.error.name);
logResult(event.target.result);
}
diff --git a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-blob-sync-expected.txt b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-blob-sync-expected.txt
index 57a280b..c8bb6f8 100644
--- a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-blob-sync-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-blob-sync-expected.txt
@@ -3,78 +3,78 @@ Received files in worker
Test reading a blob containing non-existent file
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing existent and non-existent file
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing empty file
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing empty text
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing empty files and empty texts
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing single file
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing single text
result size: 5
result: First
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing single text as data URL
result size: 21
result: data:;base64,Rmlyc3Q=
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing single text as data URL (optional content type provided)
result size: 29
result: data:type/foo;base64,Rmlyc3Q=
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing single ArrayBuffer
result size: 9
result: 0x0 0x1 0x2 0x80 0x81 0x82 0xfd 0xfe 0xff
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing sliced file
result size: 5
result: onder
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing sliced text
result size: 4
result: irst
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing sliced ArrayBuffer
result size: 8
result: 0x1 0x2 0x80 0x81 0x82 0xfd 0xfe 0xff
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing multiple files
result size: 19
result: HelloWonderfulWorld
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing multiple texts
result size: 16
result: FirstSecondThird
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a blob containing multiple ArrayBuffer
result size: 9
result: 0x0 0x1 0x2 0x80 0x81 0x82 0xfd 0xfe 0xff
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a hybrid blob
result size: 38
result: FirstHelloSecondWonderfulWorldThird012
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a sliced hybrid blob
result size: 12
result: lloSecondWon
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a triple-sliced hybrid blob
result size: 30
result: ondWonderfulWorldThird012Foolo
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
DONE
diff --git a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-async-expected.txt b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-async-expected.txt
index 3877ddb..1d4104b 100644
--- a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-async-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-async-expected.txt
@@ -4,28 +4,28 @@ Test reading a non-existent file as array buffer
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as binary string
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as text
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading a non-existent file as data URL
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
Test reading an empty file as array buffer
@@ -208,7 +208,7 @@ Test reading again after failed read
readyState: 0
Received error event
readyState: 2
-error code: 1
+error name: NotFoundError
result: null
Received loadend event
readyState after recalling read method: 1
diff --git a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-sync-expected.txt b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-sync-expected.txt
index cbe3e79..43813ba 100644
--- a/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-sync-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/files/workers/worker-read-file-sync-expected.txt
@@ -1,81 +1,81 @@
Received files in worker
Test reading a non-existent file as array buffer
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a non-existent file as binary string
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a non-existent file as text
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a non-existent file as data URL
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading an empty file as array buffer
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading an empty file as binary string
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading an empty file as text
result size: 0
result:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading an empty file as data URL
result size: 5
result: data:
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-8 file as array buffer
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-8 file as binary string
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a binary file as array buffer
result size: 9
result: 0x0 0x1 0x2 0x80 0x81 0x82 0xfd 0xfe 0xff
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a binary file as binary string
result size: 9
result: 0x0 0x1 0x2 0x80 0x81 0x82 0xfd 0xfe 0xff
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-8 file as text
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-16BE BOM file as text
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-16LE BOM file as text
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-8 BOM file as text
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-16BE file as text with UTF-16BE encoding
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-16BE BOM file as text with UTF8 encoding
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-16BE BOM file as text with invalid encoding
result size: 5
result: Hello
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test reading a UTF-8 file as data URL
result size: 31
result: data:text/plain;base64,SGVsbG8=
-Received exception, code: 8, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
+Received exception, name: NotFoundError, message: A requested file or directory could not be found at the time an operation was processed.
Test calling multiple read methods in a row
result size: 5
result: Hello
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/cross-filesystem-op.html b/third_party/WebKit/LayoutTests/fast/filesystem/cross-filesystem-op.html
index 962a3ea..5c1f8f7 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/cross-filesystem-op.html
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/cross-filesystem-op.html
@@ -50,7 +50,7 @@ function errorCallback(msg)
{
return function(e) {
console.log(e);
- log('ERROR:' + msg + ': ' + e.code);
+ log('ERROR:' + msg + ': ' + e.name);
if (window.testRunner)
testRunner.notifyDone();
};
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/file-after-reload-crash.html b/third_party/WebKit/LayoutTests/fast/filesystem/file-after-reload-crash.html
index 147a382..a6aaaee 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/file-after-reload-crash.html
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/file-after-reload-crash.html
@@ -20,7 +20,7 @@ if (location.search != '?reenter') {
}
function onError(msg, e) {
- document.body.innerText = 'FAIL: ' + e.code + ' msg = ' + msg;
+ document.body.innerText = 'FAIL: ' + e.name + ' msg = ' + msg;
if (window.testRunner)
testRunner.notifyDone();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/file-metadata-after-write.html b/third_party/WebKit/LayoutTests/fast/filesystem/file-metadata-after-write.html
index e77d286..427ec97 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/file-metadata-after-write.html
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/file-metadata-after-write.html
@@ -63,7 +63,7 @@ function log(text)
function onError(e)
{
- log('ERROR: ' + e.code);
+ log('ERROR: ' + e.name);
console.log(e);
cleanup();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/not-enough-arguments.html b/third_party/WebKit/LayoutTests/fast/filesystem/not-enough-arguments.html
index e535a7c..7ccb68c 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/not-enough-arguments.html
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/not-enough-arguments.html
@@ -9,7 +9,7 @@ description('This test tries calling various filesystem functions with too few a
function errorCallback(error)
{
- debug("Error occured:" + error.code);
+ debug("Error occured:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-copy-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-copy-expected.txt
index fc2aa4e..4ad5146 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-copy-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-copy-expected.txt
@@ -19,26 +19,26 @@ PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
PASS Verified entry: ENTRY {path:/c/b name:b type:FILE}
* Running: CopyFileWithEmptyNameToSameDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: CopyFileWithSameName
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: CopyForNonExistentEntry
PASS Succeeded: "/a/b".remove()
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
* Running: CopyEntryToNonExistentDirectory
PASS Succeeded: "/c".remove()
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: CopyEntryToItsChild
-PASS this.expectedErrorCode + "" is "9"
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b/c name:c type:DIRECTORY}
@@ -63,20 +63,20 @@ PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
PASS Verified entry: ENTRY {path:/c/b name:b type:FILE}
* Running: OverwritingCopyFileToDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:FILE}
PASS Verified entry: ENTRY {path:/b name:b type:DIRECTORY}
* Running: OverwritingCopyDirectoryToFile
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b name:b type:FILE}
* Running: OverwritingCopyFileToNonemptyDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:FILE}
PASS Verified entry: ENTRY {path:/b name:b type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b/c name:c type:FILE}
* Running: OverwritingCopyDirectoryToNonemptyDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-get-entry-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-get-entry-expected.txt
index 8afdebb..93a51cb 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-get-entry-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-get-entry-expected.txt
@@ -62,21 +62,21 @@ PASS this.environment[this.entry.fullPath].isDirectory + "" is "false"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b name:b type:FILE}
* Running: GetNonExistent
-PASS this.expectedErrorCode + "" is "1"
-PASS this.expectedErrorCode + "" is "1"
-PASS this.expectedErrorCode + "" is "1"
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
+PASS this.expectedError + "" is "NotFoundError"
+PASS this.expectedError + "" is "NotFoundError"
+PASS this.expectedError + "" is "NotFoundError"
* Running: GetFileForDirectory
-PASS this.expectedErrorCode + "" is "11"
-PASS this.expectedErrorCode + "" is "11"
+PASS this.expectedError + "" is "TypeMismatchError"
+PASS this.expectedError + "" is "TypeMismatchError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
* Running: GetDirectoryForFile
-PASS this.expectedErrorCode + "" is "11"
-PASS this.expectedErrorCode + "" is "11"
+PASS this.expectedError + "" is "TypeMismatchError"
+PASS this.expectedError + "" is "TypeMismatchError"
PASS Verified entry: ENTRY {path:/a name:a type:FILE}
* Running: CreateWithExclusive
-PASS this.expectedErrorCode + "" is "9"
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b name:b type:FILE}
Finished running tests.
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-get-metadata-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-get-metadata-expected.txt
index 3c764f9..c72e342 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-get-metadata-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-get-metadata-expected.txt
@@ -15,7 +15,7 @@ PASS Succeeded: "/".getFile("/b")
PASS Succeeded: "/b".getMetadata()
PASS this.environment["/b.returned.modificationTime"] is >= this.roundedStartDate
PASS Succeeded: "/tmp".remove()
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
PASS this.environment["/a.returned.modificationTime"] is >= this.environment["/.returned.modificationTime"]
PASS this.environment["/b.returned.modificationTime"] is >= this.environment["/.returned.modificationTime"]
PASS this.environment["/b.returned.modificationTime"] is >= this.environment["/a.returned.modificationTime"]
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-move-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-move-expected.txt
index 6594210..c86328e 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-move-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-move-expected.txt
@@ -19,26 +19,26 @@ PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry does NOT exist: /a/b
PASS Verified entry: ENTRY {path:/c/b name:b type:FILE}
* Running: MoveFileWithEmptyNameToSameDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: MoveFileWithSameName
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: MoveForNonExistentEntry
PASS Succeeded: "/a/b".remove()
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
* Running: MoveEntryToNonExistentDirectory
PASS Succeeded: "/c".remove()
-PASS this.expectedErrorCode + "" is "1"
+PASS this.expectedError + "" is "NotFoundError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
* Running: MoveEntryToItsChild
-PASS this.expectedErrorCode + "" is "9"
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b/c name:c type:DIRECTORY}
@@ -58,20 +58,20 @@ PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
PASS Verified entry: ENTRY {path:/c/b name:b type:FILE}
PASS Verified entry does NOT exist: /a
* Running: OverwritingMoveFileToDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:FILE}
PASS Verified entry: ENTRY {path:/b name:b type:DIRECTORY}
* Running: OverwritingMoveDirectoryToFile
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b name:b type:FILE}
* Running: OverwritingMoveFileToNonemptyDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:FILE}
PASS Verified entry: ENTRY {path:/b name:b type:DIRECTORY}
PASS Verified entry: ENTRY {path:/b/c name:c type:FILE}
* Running: OverwritingMoveDirectoryToNonemptyDirectory
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:FILE}
PASS Verified entry: ENTRY {path:/c name:c type:DIRECTORY}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-remove-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-remove-expected.txt
index 82af44c..1eaf757 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-remove-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-remove-expected.txt
@@ -1,11 +1,11 @@
* Running: RemoveSimple
PASS Succeeded: "/a".remove()
PASS Succeeded: "/b".remove()
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry does NOT exist: /a
PASS Verified entry does NOT exist: /b
* Running: RemoveNonRecursiveWithChildren
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/a name:a type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/b name:b type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a/c name:c type:FILE}
@@ -14,7 +14,7 @@ PASS Succeeded: "/a".removeRecursively()
PASS Verified entry does NOT exist: /a
* Running: RemoveRecursiveWithChildren
PASS Succeeded: "/a".removeRecursively()
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry does NOT exist: /a
Finished running tests.
PASS successfullyParsed is true
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-chars-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-chars-expected.txt
index 2449446..11ad0ed 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-chars-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-chars-expected.txt
@@ -18,15 +18,15 @@ PASS Succeeded: "/".getFile("ab?")
PASS Succeeded: "/".getFile("ab*")
PASS Succeeded: "/".getFile("ab"")
PASS Succeeded: "/".getFile("ab|")
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Succeeded: "/ab".copyTo("/", " a<b")
PASS Succeeded: "/ab".copyTo("/", " a:b")
PASS Succeeded: "/ab".copyTo("/", " a?b")
PASS Succeeded: "/ab".copyTo("/", " a*b")
PASS Succeeded: "/ab".copyTo("/", " a"b")
PASS Succeeded: "/ab".copyTo("/", " a|b")
-PASS this.expectedErrorCode + "" is "9"
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Verified entry: ENTRY {path:/ab name:ab type:DIRECTORY}
PASS Verified entry: ENTRY {path:/a<b name:a<b type:FILE}
PASS Verified entry: ENTRY {path:/ a|b name: a|b type:DIRECTORY}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-names-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-names-expected.txt
index 89bd2d5..a6cb04d 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-names-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-names-expected.txt
@@ -1,6 +1,6 @@
* Running: RestrictedNames
-PASS this.expectedErrorCode + "" is "2"
-PASS this.expectedErrorCode + "" is "2"
+PASS this.expectedError + "" is "SecurityError"
+PASS this.expectedError + "" is "SecurityError"
PASS Succeeded: "/".getFile("con")
PASS Succeeded: "/".getFile("CON")
PASS Succeeded: "/".getFile("Con")
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-unicode-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-unicode-expected.txt
index 8cbc0a2..acb2ce0 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-unicode-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/op-restricted-unicode-expected.txt
@@ -1,6 +1,6 @@
* Running: RestrictedUnicodeChars
PASS Succeeded: "/".getFile("ab")
-PASS this.expectedErrorCode + "" is "9"
+PASS this.expectedError + "" is "InvalidModificationError"
PASS Succeeded: "/".getFile("ab")
PASS Succeeded: "/".getFile("ab")
PASS Succeeded: "/".getFile("ab")
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/async-operations.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/async-operations.js
index e509b9b..f0fff3f 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/async-operations.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/async-operations.js
@@ -18,7 +18,7 @@ var dirsCount = 0;
var reader = null;
function errorCallback(error) {
- debug("Got error: " + error.code);
+ debug("Got error: " + error.name);
removeAllInDirectory(fileSystem.root);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/directory-entry-to-uri.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/directory-entry-to-uri.js
index 92e8e2c..464e46b 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/directory-entry-to-uri.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/directory-entry-to-uri.js
@@ -11,7 +11,7 @@ var testDirectoryName = 'testDirectory';
var testDirectoryURI = null;
function errorCallback(error) {
- testFailed("Error occured:" + error.code);
+ testFailed("Error occured:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-entry-to-uri.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-entry-to-uri.js
index c5514e7..f086e54 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-entry-to-uri.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-entry-to-uri.js
@@ -11,7 +11,7 @@ var testFileName = 'testFileEntry.txt';
var testFileURI = null;
function errorCallback(error) {
- testFailed("Error occured:" + error.code);
+ testFailed("Error occured:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-from-file-entry.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-from-file-entry.js
index d8c1219..49633ea 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-from-file-entry.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-from-file-entry.js
@@ -12,7 +12,7 @@ var testFileEntry = null;
var testFile = null;
function errorCallback(error) {
- testFailed("Error occured:" + error.code);
+ testFailed("Error occured:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-writer-abort.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-writer-abort.js
index 499a7df..b3f62dc 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-writer-abort.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/file-writer-abort.js
@@ -38,7 +38,7 @@ function onWrite(e) {
function onAbort(e) {
assert(writer.readyState == writer.DONE);
- assert(writer.error.code == writer.error.ABORT_ERR);
+ assert(writer.error.name == "AbortError");
assert(sawWriteStart);
assert(!sawWriteEnd);
assert(!sawAbort);
@@ -49,7 +49,7 @@ function onAbort(e) {
function onWriteEnd(e) {
assert(writer.readyState == writer.DONE);
- assert(writer.error.code == writer.error.ABORT_ERR);
+ assert(writer.error.name == "AbortError");
assert(sawWriteStart);
assert(sawAbort);
assert(!sawWriteEnd);
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-copy.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-copy.js
index 1717529..7e4b364 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-copy.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-copy.js
@@ -68,7 +68,7 @@ var testCases = [
{fullPath:'/a/b'},
],
tests: [
- function(helper) { helper.copy('/a/b', '/a', null, FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.copy('/a/b', '/a', null, 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -82,7 +82,7 @@ var testCases = [
{fullPath:'/a/b'},
],
tests: [
- function(helper) { helper.copy('/a/b', '/a', 'b', FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.copy('/a/b', '/a', 'b', 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -98,7 +98,7 @@ var testCases = [
],
tests: [
function(helper) { helper.remove('/a/b'); },
- function(helper) { helper.copy('/a/b', '/c', 'b', FileError.NOT_FOUND_ERR); },
+ function(helper) { helper.copy('/a/b', '/c', 'b', 'NotFoundError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -114,7 +114,7 @@ var testCases = [
],
tests: [
function(helper) { helper.remove('/c'); },
- function(helper) { helper.copy('/a/b', '/c', 'b', FileError.NOT_FOUND_ERR); },
+ function(helper) { helper.copy('/a/b', '/c', 'b', 'NotFoundError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -129,8 +129,8 @@ var testCases = [
{fullPath:'/a/b/c', isDirectory:true},
],
tests: [
- function(helper) { helper.copy('/a', '/a/b', 'd', FileError.INVALID_MODIFICATION_ERR); },
- function(helper) { helper.copy('/a/b', '/a/b/c', 'd', FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.copy('/a', '/a/b', 'd', 'InvalidModificationError'); },
+ function(helper) { helper.copy('/a/b', '/a/b/c', 'd', 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -199,7 +199,7 @@ var testCases = [
{fullPath:"/b", isDirectory: true},
],
tests: [
- function(helper) {helper.copy("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.copy("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a"},
@@ -213,7 +213,7 @@ var testCases = [
{fullPath:"/b"},
],
tests: [
- function(helper) {helper.copy("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.copy("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a", isDirectory: true},
@@ -228,7 +228,7 @@ var testCases = [
{fullPath:"/b/c"},
],
tests: [
- function(helper) {helper.copy("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.copy("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a"},
@@ -245,7 +245,7 @@ var testCases = [
{fullPath:"/c/d"},
],
tests: [
- function(helper) {helper.copy("/a","/","c",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.copy("/a","/","c",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a", isDirectory: true},
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-entry.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-entry.js
index 29073c3..d879e38 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-entry.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-entry.js
@@ -54,14 +54,14 @@ var testCases = [
function(helper) { helper.getDirectory('/a', '/a/../../d', {create:true}); },
function(helper) { helper.getDirectory('/a', '/a/../../b/./c/../../../../../e', {create:true}); },
// TODO(jschuh): Re-enable after crbug.com/181617 is fixed.
- //function(helper) { helper.getDirectory('/a', '/a/../.../g', {create:true}, FileError.NOT_FOUND_ERR); },
+ //function(helper) { helper.getDirectory('/a', '/a/../.../g', {create:true}, 'NotFoundError'); },
function(helper) { helper.getFile('/a', './b.txt', {create:true}); },
function(helper) { helper.getFile('/a', '../b.txt', {create:true}); },
function(helper) { helper.getFile('/a', '../../b/c.txt', {create:true}); },
function(helper) { helper.getFile('/a', '/a/../../d.txt', {create:true}); },
function(helper) { helper.getFile('/a', '/a/../../b/./c/../../../../../e.txt', {create:true}); },
// TODO(jschuh): Re-enable after crbug.com/181617 is fixed.
- //function(helper) { helper.getFile('/a', '/a/../.../g.txt', {create:true}, FileError.NOT_FOUND_ERR); },
+ //function(helper) { helper.getFile('/a', '/a/../.../g.txt', {create:true}, 'NotFoundError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -103,10 +103,10 @@ var testCases = [
name: 'GetNonExistent',
precondition: [ ],
tests: [
- function(helper) { helper.getDirectory('/', 'a', {}, FileError.NOT_FOUND_ERR); },
- function(helper) { helper.getFile('/', 'b', {}, FileError.NOT_FOUND_ERR); },
- function(helper) { helper.getDirectory('/', '/nonexistent/a', {create:true}, FileError.NOT_FOUND_ERR); },
- function(helper) { helper.getFile('/', '/nonexistent/b', {create:true}, FileError.NOT_FOUND_ERR); }
+ function(helper) { helper.getDirectory('/', 'a', {}, 'NotFoundError'); },
+ function(helper) { helper.getFile('/', 'b', {}, 'NotFoundError'); },
+ function(helper) { helper.getDirectory('/', '/nonexistent/a', {create:true}, 'NotFoundError'); },
+ function(helper) { helper.getFile('/', '/nonexistent/b', {create:true}, 'NotFoundError'); }
],
postcondition: [ ],
},
@@ -116,8 +116,8 @@ var testCases = [
{fullPath:'/a', isDirectory:true}
],
tests: [
- function(helper) { helper.getFile('/', 'a', {}, FileError.TYPE_MISMATCH_ERR); },
- function(helper) { helper.getFile('/', '/a', {}, FileError.TYPE_MISMATCH_ERR); },
+ function(helper) { helper.getFile('/', 'a', {}, 'TypeMismatchError'); },
+ function(helper) { helper.getFile('/', '/a', {}, 'TypeMismatchError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true}
@@ -129,8 +129,8 @@ var testCases = [
{fullPath:'/a'}
],
tests: [
- function(helper) { helper.getDirectory('/', 'a', {}, FileError.TYPE_MISMATCH_ERR); },
- function(helper) { helper.getDirectory('/', '/a', {}, FileError.TYPE_MISMATCH_ERR); },
+ function(helper) { helper.getDirectory('/', 'a', {}, 'TypeMismatchError'); },
+ function(helper) { helper.getDirectory('/', '/a', {}, 'TypeMismatchError'); },
],
postcondition: [
{fullPath:'/a'}
@@ -143,8 +143,8 @@ var testCases = [
{fullPath:'/b'}
],
tests: [
- function(helper) { helper.getDirectory('/', 'a', {create:true, exclusive:true}, FileError.INVALID_MODIFICATION_ERR); },
- function(helper) { helper.getFile('/', 'b', {create:true, exclusive:true}, FileError.INVALID_MODIFICATION_ERR); }
+ function(helper) { helper.getDirectory('/', 'a', {create:true, exclusive:true}, 'InvalidModificationError'); },
+ function(helper) { helper.getFile('/', 'b', {create:true, exclusive:true}, 'InvalidModificationError'); }
],
postcondition: [
{fullPath:'/a', isDirectory:true},
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-metadata.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-metadata.js
index 8356030..a1c6d4b 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-metadata.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-get-metadata.js
@@ -17,7 +17,7 @@ var testCases = [
function(helper) { helper.getFile('/', '/b', {create:true}); },
function(helper) { helper.getMetadata('/b'); },
function(helper) { helper.remove('/tmp'); },
- function(helper) { helper.getMetadata('/tmp', FileError.NOT_FOUND_ERR); },
+ function(helper) { helper.getMetadata('/tmp', 'NotFoundError'); },
function(helper) { helper.shouldBeGreaterThanOrEqual('/a.returned.modificationTime', '/.returned.modificationTime'); },
function(helper) { helper.shouldBeGreaterThanOrEqual('/b.returned.modificationTime', '/.returned.modificationTime'); },
function(helper) { helper.shouldBeGreaterThanOrEqual('/b.returned.modificationTime', '/a.returned.modificationTime'); }
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-move.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-move.js
index 1341a43..07d6dcb 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-move.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-move.js
@@ -68,7 +68,7 @@ var testCases = [
{fullPath:'/a/b'},
],
tests: [
- function(helper) { helper.move('/a/b', '/a', null, FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.move('/a/b', '/a', null, 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -82,7 +82,7 @@ var testCases = [
{fullPath:'/a/b'},
],
tests: [
- function(helper) { helper.move('/a/b', '/a', 'b', FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.move('/a/b', '/a', 'b', 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -98,7 +98,7 @@ var testCases = [
],
tests: [
function(helper) { helper.remove('/a/b'); },
- function(helper) { helper.move('/a/b', '/c', 'b', FileError.NOT_FOUND_ERR); },
+ function(helper) { helper.move('/a/b', '/c', 'b', 'NotFoundError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -114,7 +114,7 @@ var testCases = [
],
tests: [
function(helper) { helper.remove('/c'); },
- function(helper) { helper.move('/a/b', '/c', 'b', FileError.NOT_FOUND_ERR); },
+ function(helper) { helper.move('/a/b', '/c', 'b', 'NotFoundError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -129,8 +129,8 @@ var testCases = [
{fullPath:'/a/b/c', isDirectory:true},
],
tests: [
- function(helper) { helper.move('/a', '/a/b', 'd', FileError.INVALID_MODIFICATION_ERR); },
- function(helper) { helper.move('/a/b', '/a/b/c', 'd', FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.move('/a', '/a/b', 'd', 'InvalidModificationError'); },
+ function(helper) { helper.move('/a/b', '/a/b/c', 'd', 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -194,7 +194,7 @@ var testCases = [
{fullPath:"/b", isDirectory: true},
],
tests: [
- function(helper) {helper.move("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.move("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a"},
@@ -208,7 +208,7 @@ var testCases = [
{fullPath:"/b"},
],
tests: [
- function(helper) {helper.move("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.move("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a", isDirectory: true},
@@ -223,7 +223,7 @@ var testCases = [
{fullPath:"/b/c"},
],
tests: [
- function(helper) {helper.move("/a","/","b",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.move("/a","/","b",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a"},
@@ -240,7 +240,7 @@ var testCases = [
{fullPath:"/c/d"},
],
tests: [
- function(helper) {helper.move("/a","/","c",FileError.INVALID_MODIFICATION_ERR);}
+ function(helper) {helper.move("/a","/","c",'InvalidModificationError');}
],
postcondition: [
{fullPath:"/a", isDirectory: true},
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-remove.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-remove.js
index bd168d6..396d74b 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-remove.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-remove.js
@@ -8,7 +8,7 @@ var testCases = [
tests: [
function(helper) { helper.remove('/a'); },
function(helper) { helper.remove('/b'); },
- function(helper) { helper.remove('/', FileError.INVALID_MODIFICATION_ERR); }
+ function(helper) { helper.remove('/', 'InvalidModificationError'); }
],
postcondition: [
{fullPath:'/a', nonexistent:true},
@@ -23,7 +23,7 @@ var testCases = [
{fullPath:'/a/c',}
],
tests: [
- function(helper) { helper.remove('/a', FileError.INVALID_MODIFICATION_ERR); }
+ function(helper) { helper.remove('/a', 'InvalidModificationError'); }
],
postcondition: [
{fullPath:'/a', isDirectory:true},
@@ -52,7 +52,7 @@ var testCases = [
],
tests: [
function(helper) { helper.removeRecursively('/a'); },
- function(helper) { helper.removeRecursively('/', FileError.INVALID_MODIFICATION_ERR); }
+ function(helper) { helper.removeRecursively('/', 'InvalidModificationError'); }
],
postcondition: [
{fullPath:'/a', nonexistent:true},
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-chars.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-chars.js
index bb7b974..d55ebe4 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-chars.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-chars.js
@@ -29,7 +29,7 @@ var testCases = [
function(helper) { helper.getFile('/', 'ab|', {create:true}, 0); },
// Only '\\' is disallowed.
- function(helper) { helper.getFile('/', 'a\\b', {create:true}, FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.getFile('/', 'a\\b', {create:true}, 'InvalidModificationError'); },
// Test for difficult characters in 'name' parameters.
function(helper) { helper.copy('/ab', '/', ' a<b', 0); },
@@ -40,8 +40,8 @@ var testCases = [
function(helper) { helper.copy('/ab', '/', ' a|b', 0); },
// 'Name' parameter cannot contain '/' or '\\'.
- function(helper) { helper.copy('/ab', '/', 'a/b', FileError.INVALID_MODIFICATION_ERR); },
- function(helper) { helper.copy('/ab', '/', 'a\\b', FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.copy('/ab', '/', 'a/b', 'InvalidModificationError'); },
+ function(helper) { helper.copy('/ab', '/', 'a\\b', 'InvalidModificationError'); },
],
postcondition: [
{fullPath:'/ab', isDirectory:true},
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-names.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-names.js
index 5419d45..3b2d0da 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-names.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-names.js
@@ -7,8 +7,8 @@ var testCases = [
{fullPath:'/c', isDirectory:true}
],
tests: [
- function(helper) { helper.getFile('/', '.', {create:true}, FileError.SECURITY_ERR); },
- function(helper) { helper.getFile('/', '..', {create:true}, FileError.SECURITY_ERR); },
+ function(helper) { helper.getFile('/', '.', {create:true}, 'SecurityError'); },
+ function(helper) { helper.getFile('/', '..', {create:true}, 'SecurityError'); },
function(helper) { helper.getFile('/', 'con', {create:true}, 0); },
function(helper) { helper.getFile('/', 'CON', {create:true}, 0); },
function(helper) { helper.getFile('/', 'Con', {create:true}, 0); },
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-unicode.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-unicode.js
index 5c1f1bf..d7aec51 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-unicode.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-restricted-unicode.js
@@ -6,7 +6,7 @@ var testCases = [
function(helper) { helper.getFile('/', 'ab', {create:true}); },
// Embedded NULs aren't allowed; anything else in the first 32 is fair game.
- function(helper) { helper.getFile('/', 'a\u0000b', {create:true}, FileError.INVALID_MODIFICATION_ERR); },
+ function(helper) { helper.getFile('/', 'a\u0000b', {create:true}, 'InvalidModificationError'); },
function(helper) { helper.getFile('/', 'a\u0001b', {create:true}, 0); },
function(helper) { helper.getFile('/', 'a\u0002b', {create:true}, 0); },
function(helper) { helper.getFile('/', 'a\u0003b', {create:true}, 0); },
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-tests-helper.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-tests-helper.js
index d408ce6..5218d7a 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-tests-helper.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/op-tests-helper.js
@@ -52,7 +52,7 @@ function createTestEnvironment(fileSystem, entries, successCallback, errorCallba
this.createErrorCallback = function(error, entry)
{
- testFailed('Got unexpected error ' + error.code + ' while creating ' + toString(entry));
+ testFailed('Got unexpected error ' + error.name + ' while creating ' + toString(entry));
this.errorCallback(error);
}
@@ -107,10 +107,10 @@ function verifyTestEnvironment(fileSystem, entries, successCallback, errorCallba
this.verifyNextEntry();
return;
}
- if (error == FileError.NOT_FOUND_ERR)
+ if (error == 'NotFoundError')
testFailed('Not found: ' + entry.fullPath);
else
- testFailed('Got unexpected error ' + error.code + ' for ' + entry.fullPath);
+ testFailed('Got unexpected error ' + error.name + ' for ' + entry.fullPath);
this.errorCallback(error);
}
@@ -161,7 +161,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testSuccessCallback = function()
{
- if (!this.expectedErrorCode) {
+ if (!this.expectedError) {
testPassed('Succeeded: ' + this.stage);
this.runNextTest();
} else
@@ -171,7 +171,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.entry = null;
this.testGetSuccessCallback = function(entry)
{
- if (!this.expectedErrorCode) {
+ if (!this.expectedError) {
testPassed('Succeeded: ' + this.stage);
this.entry = entry;
shouldBe.apply(this, ['this.environment[this.entry.fullPath].fullPath', '"' + entry.fullPath + '"']);
@@ -184,7 +184,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testCreateSuccessCallback = function(entry)
{
- if (!this.expectedErrorCode) {
+ if (!this.expectedError) {
testPassed('Succeeded: ' + this.stage);
this.environment[entry.fullPath] = entry;
this.runNextTest();
@@ -194,7 +194,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testGetParentSuccessCallback = function(entry)
{
- if (!this.expectedErrorCode) {
+ if (!this.expectedError) {
testPassed('Succeeded: ' + this.stage);
debug('Parent entry: ' + toString(entry));
this.runNextTest();
@@ -204,7 +204,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testReadEntriesSuccessCallback = function(entries)
{
- if (this.expectedErrorCode)
+ if (this.expectedError)
testFailed('Unexpectedly succeeded while ' + this.stage);
this.readEntries.push.apply(this.readEntries, entries);
@@ -221,7 +221,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testMetadataSuccessCallback = function(metadata, entry)
{
- if (!this.expectedErrorCode) {
+ if (!this.expectedError) {
testPassed('Succeeded: ' + this.stage);
var symbol = entry + '.returned.modificationTime';
this.environment[symbol] = metadata.modificationTime;
@@ -242,80 +242,80 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.testErrorCallback = function(error)
{
- if (this.expectedErrorCode) {
- shouldBe.apply(this, ['this.expectedErrorCode + ""', '"' + error.code + '"']);
+ if (this.expectedError) {
+ shouldBe.apply(this, ['this.expectedError + ""', '"' + error.name + '"']);
this.runNextTest();
} else {
- testFailed('Got unexpected error ' + error.code + ' while ' + this.stage);
+ testFailed('Got unexpected error ' + error.name + ' while ' + this.stage);
this.errorCallback(error);
}
};
// Operations ---------------------------------------------------
- this.getFile = function(entry, path, flags, expectedErrorCode)
+ this.getFile = function(entry, path, flags, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".getFile("' + path + '")';
var successCallback = (flags && flags.create) ? this.testCreateSuccessCallback : this.testGetSuccessCallback;
this.environment[entry].getFile(path, flags, bindCallback(this, successCallback), bindCallback(this, this.testErrorCallback));
};
- this.getDirectory = function(entry, path, flags, expectedErrorCode)
+ this.getDirectory = function(entry, path, flags, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".getDirectory("' + path + '")';
var successCallback = (flags && flags.create) ? this.testCreateSuccessCallback : this.testGetSuccessCallback;
this.environment[entry].getDirectory(path, flags, bindCallback(this, successCallback), bindCallback(this, this.testErrorCallback));
};
- this.getParent = function(entry, expectedErrorCode)
+ this.getParent = function(entry, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".getParent()';
this.environment[entry].getParent(bindCallback(this, this.testGetParentSuccessCallback), bindCallback(this, this.testErrorCallback));
};
- this.getMetadata = function(entry, expectedErrorCode)
+ this.getMetadata = function(entry, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".getMetadata()';
this.environment[entry].getMetadata(bindCallback(this, this.testMetadataSuccessCallback, entry), bindCallback(this, this.testErrorCallback));
};
- this.remove = function(entry, expectedErrorCode)
+ this.remove = function(entry, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".remove()';
this.environment[entry].remove(bindCallback(this, this.testSuccessCallback), bindCallback(this, this.testErrorCallback));
};
- this.removeRecursively = function(entry, expectedErrorCode)
+ this.removeRecursively = function(entry, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".removeRecursively()';
this.environment[entry].removeRecursively(bindCallback(this, this.testSuccessCallback), bindCallback(this, this.testErrorCallback));
};
- this.readDirectory = function(entry, expectedErrorCode)
+ this.readDirectory = function(entry, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.readEntries = [];
this.stage = '"' + entry + '".createReader().readEntries()';
this.currentReader = this.environment[entry].createReader();
this.currentReader.readEntries(bindCallback(this, this.testReadEntriesSuccessCallback), bindCallback(this, this.testErrorCallback));
};
- this.copy = function(entry, destinationParent, newName, expectedErrorCode)
+ this.copy = function(entry, destinationParent, newName, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".copyTo("' + destinationParent + '", "' + newName + '")';
this.environment[entry].copyTo(this.environment[destinationParent], newName, bindCallback(this, this.testSuccessCallback), bindCallback(this, this.testErrorCallback));
};
- this.move = function(entry, destinationParent, newName, expectedErrorCode)
+ this.move = function(entry, destinationParent, newName, expectedError)
{
- this.expectedErrorCode = expectedErrorCode;
+ this.expectedError = expectedError;
this.stage = '"' + entry + '".moveTo("' + destinationParent + '", "' + newName + '")';
this.environment[entry].moveTo(this.environment[destinationParent], newName, bindCallback(this, this.testSuccessCallback), bindCallback(this, this.testErrorCallback));
};
@@ -335,7 +335,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
//---------------------------------------------------------------
this.start = function()
{
- this.expectedErrorCode = '';
+ this.expectedError = '';
this.stage = 'resetting filesystem';
// Record rounded start date (current time minus 999 msec) here for the comparison. Entry.getMetadata() may return the last mod time in seconds accuracy while new Date() is milliseconds accuracy.
this.roundedStartDate = new Date((new Date()).getTime() - 999);
@@ -344,7 +344,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.setUp = function()
{
- this.expectedErrorCode = '';
+ this.expectedError = '';
this.stage = 'setting up test precondition';
createTestEnvironment(this.fileSystem, this.testCase.precondition, bindCallback(this, this.runTests), bindCallback(this, this.testErrorCallback));
};
@@ -368,7 +368,7 @@ function runOperationTest(fileSystem, testCase, successCallback, errorCallback)
this.verify = function()
{
- this.expectedErrorCode = '';
+ this.expectedError = '';
if (!this.testCase.postcondition) {
this.successCallback();
return;
@@ -397,8 +397,8 @@ function runNextTest() {
}
function errorCallback(error) {
- if (error && error.code)
- testFailed('Got error ' + error.code);
+ if (error && error.name)
+ testFailed('Got error ' + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-persistent.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-persistent.js
index 7e8580f..e3bfecd 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-persistent.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-persistent.js
@@ -9,7 +9,7 @@ description("requestFileSystem PERSISTENT test.");
var fileSystem = null;
function errorCallback(error) {
- debug("Error occured while requesting a PERSISTENT file system:" + error.code);
+ debug("Error occured while requesting a PERSISTENT file system:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getdirectory.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getdirectory.js
index fb9fb2f..68a152c 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getdirectory.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getdirectory.js
@@ -9,7 +9,7 @@ description("DirectoryEntry required arguments test.");
var fileSystem = null;
function errorCallback(error) {
- debug("Error occured while requesting a TEMPORARY file system:" + error.code);
+ debug("Error occured while requesting a TEMPORARY file system:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getfile.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getfile.js
index 65efd59..146f69e 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getfile.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getfile.js
@@ -9,7 +9,7 @@ description("DirectoryEntry required arguments test.");
var fileSystem = null;
function errorCallback(error) {
- debug("Error occured while requesting a TEMPORARY file system:" + error.code);
+ debug("Error occured while requesting a TEMPORARY file system:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getmetadata.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getmetadata.js
index 1c6affd..df0d036 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getmetadata.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-getmetadata.js
@@ -9,7 +9,7 @@ description("DirectoryEntry.getMetadata required arguments test.");
var fileSystem = null;
function errorCallback(error) {
- debug("Error occured while requesting a TEMPORARY file system:" + error.code);
+ debug("Error occured while requesting a TEMPORARY file system:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-remove.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-remove.js
index 654da74..747057d 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-remove.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-required-arguments-remove.js
@@ -9,7 +9,7 @@ description("Entry.remove() required arguments test.");
var fileSystem = null;
function errorCallback(error) {
- debug("Error occured while requesting a TEMPORARY file system:" + error.code);
+ debug("Error occured while requesting a TEMPORARY file system:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-temporary.js b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-temporary.js
index c7b2824..5329f36 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-temporary.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/resources/simple-temporary.js
@@ -9,7 +9,7 @@ description("requestFileSystem TEMPORARY test.");
var fileSystem = null;
function errorCallback(error) {
- debug('Error occured while requesting a TEMPORARY file system:' + error.code);
+ debug('Error occured while requesting a TEMPORARY file system:' + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-reference.js b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-reference.js
index 7f755f3..0fb0109 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-reference.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-reference.js
@@ -5,7 +5,7 @@ var testEntries = null;
function errorCallback(error)
{
- testFailed("Error occurred: " + error.code);
+ testFailed("Error occurred: " + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-unserializable.js b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-unserializable.js
index e86b3c41..96350c8 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-unserializable.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/filesystem-unserializable.js
@@ -2,7 +2,7 @@ description("This tests if the filesystem object is unserializable by default");
function errorCallback(error)
{
- testFailed("Error occurred: " + error.code);
+ testFailed("Error occurred: " + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js
index 92e0c49..0c0755f 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js
@@ -28,7 +28,7 @@ function runNextTest(v) {
}
function errorCallback(error) {
- debug("Error occured during requesting Temporary FileSystem:" + error.code);
+ debug("Error occured during requesting Temporary FileSystem:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/read-directory.js b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/read-directory.js
index 313db53..a401b65 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/read-directory.js
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/script-tests/read-directory.js
@@ -25,7 +25,7 @@ function endTest()
function errorCallback(error)
{
- debug("Error occured:" + error.code);
+ debug("Error occured:" + error.name);
endTest();
}
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/simple-readonly-file-object.html b/third_party/WebKit/LayoutTests/fast/filesystem/simple-readonly-file-object.html
index 8665431..b747dac 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/simple-readonly-file-object.html
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/simple-readonly-file-object.html
@@ -29,7 +29,7 @@ function setReadonlyProperty(property, value)
}
function errorCallback(error) {
- testFailed("Error occured:" + error.code);
+ testFailed("Error occured:" + error.name);
finishJSTest();
}
diff --git a/third_party/WebKit/LayoutTests/http/tests/filesystem/resolve-uri-expected.txt b/third_party/WebKit/LayoutTests/http/tests/filesystem/resolve-uri-expected.txt
index 23720f5..bdac8b5 100644
--- a/third_party/WebKit/LayoutTests/http/tests/filesystem/resolve-uri-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/filesystem/resolve-uri-expected.txt
@@ -10,19 +10,19 @@ PASS isFile is true
PASS expectedPath is actualPath
PASS isFile is true
* Resolving a URL with the wrong security origin (domain)
-PASS FileError.SECURITY_ERR is errorCode
+PASS "SecurityError" is errorName
* Resolving a URL with the wrong security origin (port)
-PASS FileError.SECURITY_ERR is errorCode
+PASS "SecurityError" is errorName
* Resolving a URL with the wrong security origin (scheme)
-PASS FileError.SECURITY_ERR is errorCode
+PASS "SecurityError" is errorName
* Resolving a completely bogus URL.
-PASS FileError.ENCODING_ERR is errorCode
+PASS "EncodingError" is errorName
* Resolving a URL with the wrong protocol
-PASS FileError.ENCODING_ERR is errorCode
+PASS "EncodingError" is errorName
* Resolving a URL with no slash between type and file
-PASS FileError.ENCODING_ERR is errorCode
+PASS "EncodingError" is errorName
* Resolving a URL with no slash between protocol and type (bogus port)
-PASS FileError.SECURITY_ERR is errorCode
+PASS "SecurityError" is errorName
* Resolve a path using backslashes
PASS expectedPath is actualPath
PASS isFile is true
diff --git a/third_party/WebKit/LayoutTests/http/tests/filesystem/script-tests/resolve-uri.js b/third_party/WebKit/LayoutTests/http/tests/filesystem/script-tests/resolve-uri.js
index 66a7064..f2af44a 100644
--- a/third_party/WebKit/LayoutTests/http/tests/filesystem/script-tests/resolve-uri.js
+++ b/third_party/WebKit/LayoutTests/http/tests/filesystem/script-tests/resolve-uri.js
@@ -9,24 +9,24 @@ var testFileName = '/testFile';
var fileSystem = null;
var expectedPath = null;
var actualPath = null;
-var errorCode = null;
+var errorName = null;
function errorCallback(error) {
- if (error && error.code)
- debug("Error occurred: " + error.code);
+ if (error && error.name)
+ debug("Error occurred: " + error.name);
testFailed("Bailing out early");
finishJSTest();
}
function expectSecurityErrAndRunNext(error) {
- errorCode = error.code;
- shouldBe("FileError.SECURITY_ERR", "errorCode");
+ errorName = error.name;
+ shouldBe('"SecurityError"', "errorName");
cleanupAndRunNext();
}
function expectEncodingErrAndRunNext(error) {
- errorCode = error.code;
- shouldBe("FileError.ENCODING_ERR", "errorCode");
+ errorName = error.name;
+ shouldBe('"EncodingError"', "errorName");
cleanupAndRunNext();
}
diff --git a/third_party/WebKit/LayoutTests/http/tests/filesystem/workers/resolve-url-expected.txt b/third_party/WebKit/LayoutTests/http/tests/filesystem/workers/resolve-url-expected.txt
index 3e5362c..a8630ca 100644
--- a/third_party/WebKit/LayoutTests/http/tests/filesystem/workers/resolve-url-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/filesystem/workers/resolve-url-expected.txt
@@ -11,19 +11,19 @@ PASS [Worker] isFile is true
PASS [Worker] expectedPath is actualPath
PASS [Worker] isFile is true
[Worker] * Resolving a URL with the wrong security origin (domain)
-PASS [Worker] FileError.SECURITY_ERR is errorCode
+PASS [Worker] "SecurityError" is errorName
[Worker] * Resolving a URL with the wrong security origin (port)
-PASS [Worker] FileError.SECURITY_ERR is errorCode
+PASS [Worker] "SecurityError" is errorName
[Worker] * Resolving a URL with the wrong security origin (scheme)
-PASS [Worker] FileError.SECURITY_ERR is errorCode
+PASS [Worker] "SecurityError" is errorName
[Worker] * Resolving a completely bogus URL.
-PASS [Worker] FileError.ENCODING_ERR is errorCode
+PASS [Worker] "EncodingError" is errorName
[Worker] * Resolving a URL with the wrong protocol
-PASS [Worker] FileError.ENCODING_ERR is errorCode
+PASS [Worker] "EncodingError" is errorName
[Worker] * Resolving a URL with no slash between type and file
-PASS [Worker] FileError.ENCODING_ERR is errorCode
+PASS [Worker] "EncodingError" is errorName
[Worker] * Resolving a URL with no slash between protocol and type (bogus port)
-PASS [Worker] FileError.SECURITY_ERR is errorCode
+PASS [Worker] "SecurityError" is errorName
[Worker] * Resolve a path using backslashes
PASS [Worker] expectedPath is actualPath
PASS [Worker] isFile is true