summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast
diff options
context:
space:
mode:
authorericu@chromium.org <ericu@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2012-01-05 09:29:16 +0000
committerericu@chromium.org <ericu@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2012-01-05 09:29:16 +0000
commitcfa6dcd6fd39f9b1774259ccb675aa66dc372bfe (patch)
tree525fb9aef74bbaa9c395de03980c45320f5a42ed /third_party/WebKit/LayoutTests/fast
parentf1002b5d6df212dc0f48aff0d9832818cb880825 (diff)
downloadchromium_src-cfa6dcd6fd39f9b1774259ccb675aa66dc372bfe.zip
chromium_src-cfa6dcd6fd39f9b1774259ccb675aa66dc372bfe.tar.gz
chromium_src-cfa6dcd6fd39f9b1774259ccb675aa66dc372bfe.tar.bz2
[fileapi] WebKitFlags should not be constructable per Directories & System spec
https://bugs.webkit.org/show_bug.cgi?id=68916 Reviewed by Eric Seidel. Source/WebCore: Remove IDL for the object and all DOM references to it. * fileapi/WebKitFlags.idl: Removed. * page/DOMWindow.idl: * workers/WorkerContext.idl: Remove references to the JSC/V8 objects compiled from the IDL. * bindings/js/JSDirectoryEntryCustom.cpp: (WebCore::JSDirectoryEntry::getFile): (WebCore::JSDirectoryEntry::getDirectory): * bindings/js/JSDirectoryEntrySyncCustom.cpp: (WebCore::getFlags): * bindings/v8/custom/V8DirectoryEntryCustom.cpp: (WebCore::V8DirectoryEntry::getDirectoryCallback): (WebCore::V8DirectoryEntry::getFileCallback): * bindings/v8/custom/V8DirectoryEntrySyncCustom.cpp: (WebCore::getFlags): Fix up build files. * WebCore.gypi: * WebCore.vcproj/WebCore.vcproj: * WebCore.xcodeproj/project.pbxproj: * WebCore/CMakeLists.txt: * WebCore/CodeGenerators.pri: * WebCore/DerivedSources.cpp: * WebCore/DerivedSources.make: * WebCore/GNUmakefile.list.am: LayoutTests: Remove a test that constructed the object; add one that tests error-handling for non-object parameters while I'm in there. * fast/filesystem/flags-passing-expected.txt: * fast/filesystem/script-tests/flags-passing.js: Remove a special case reference to the global WebKitFlags constructor. * fast/dom/script-tests/prototype-inheritance.js: git-svn-id: svn://svn.chromium.org/blink/trunk@104126 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Diffstat (limited to 'third_party/WebKit/LayoutTests/fast')
-rw-r--r--third_party/WebKit/LayoutTests/fast/dom/script-tests/prototype-inheritance.js1
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/flags-passing-expected.txt8
-rw-r--r--third_party/WebKit/LayoutTests/fast/filesystem/script-tests/flags-passing.js37
3 files changed, 16 insertions, 30 deletions
diff --git a/third_party/WebKit/LayoutTests/fast/dom/script-tests/prototype-inheritance.js b/third_party/WebKit/LayoutTests/fast/dom/script-tests/prototype-inheritance.js
index 5283d25..6b87361 100644
--- a/third_party/WebKit/LayoutTests/fast/dom/script-tests/prototype-inheritance.js
+++ b/third_party/WebKit/LayoutTests/fast/dom/script-tests/prototype-inheritance.js
@@ -28,7 +28,6 @@ var skippedProperties = [
"DeviceOrientationEvent",
"DeviceMotionEvent",
"TEMPORARY", "PERSISTENT",
- "WebKitFlags",
"v8Locale",
// Ignore this property because it only appears in debug builds.
"jscprint"
diff --git a/third_party/WebKit/LayoutTests/fast/filesystem/flags-passing-expected.txt b/third_party/WebKit/LayoutTests/fast/filesystem/flags-passing-expected.txt
index 11e2039..5c87552 100644
--- a/third_party/WebKit/LayoutTests/fast/filesystem/flags-passing-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/filesystem/flags-passing-expected.txt
@@ -1,16 +1,14 @@
-Passing Flags parameter tests. This test checks if passing Flags parameters (in Object format or in JSON format) to DirectoryEntry.getFile does not crash and works as expected.
+Passing Flags parameter tests. This test checks if passing Flags parameters to DirectoryEntry.getFile does not crash and works as expected.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-* Passing a WebKitFlags object.
-* Recycling the same WebKitFlags object.
-* Passing a WebKitFlags object (with exclusive=true).
* Passing JSON Flags object.
* Passing JSON Flags object (with exclusive=true).
* Passing null as a WebKitFlags parameter.
+* Passing a number as a WebKitFlags parameter.
Finished running tests.
-PASS expectedCallbacksCount is 3
+PASS expectedCallbacksCount is 1
PASS unexpectedCallbacksCount is 0
PASS successfullyParsed is true
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 d2d06b2..2e5fbee 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
@@ -1,4 +1,4 @@
-description("Passing Flags parameter tests. This test checks if passing Flags parameters (in Object format or in JSON format) to DirectoryEntry.getFile does not crash and works as expected.");
+description("Passing Flags parameter tests. This test checks if passing Flags parameters to DirectoryEntry.getFile does not crash and works as expected.");
var testFileName = '/non_existent_file';
var fileSystem = null;
@@ -9,18 +9,18 @@ var unexpected = function(e) { unexpectedCallbacksCount++; };
var testsList = [
'runObjectTest',
- 'runObjectTestWithExclusive',
'cleanupAndRunNext',
'runJSONTest',
'runJSONTestWithExclusive',
- 'runNullTest'
+ 'runNullTest',
+ 'runNonObjectTest'
];
var testCounter = 0;
function runNextTest(v) {
if (testCounter == testsList.length) {
debug("Finished running tests.");
- shouldBe('expectedCallbacksCount', '3');
+ shouldBe('expectedCallbacksCount', '1');
shouldBe('unexpectedCallbacksCount', '0');
finishJSTest();
} else
@@ -40,29 +40,18 @@ function runNullTest(v) {
fileSystem.root.getFile(testFileName, null, runNextTest, errorCallback);
}
-function runObjectTest(v) {
- debug("* Passing a WebKitFlags object.");
- var flags = new WebKitFlags();
- flags.create = false;
-
- fileSystem.root.getFile(testFileName, flags, unexpected, expected);
-
- debug("* Recycling the same WebKitFlags object.");
-
- fileSystem.root.getFile(testFileName, flags, unexpected, expected);
+function runNonObjectTest(v) {
+ debug("* Passing a number as a WebKitFlags parameter.");
- flags.create = true;
- fileSystem.root.getFile(testFileName, flags, runNextTest, errorCallback);
+ // This should be ok and we treat it as {false, false} Flags.
+ fileSystem.root.getFile(testFileName, 7, runNextTest, errorCallback);
}
-function runObjectTestWithExclusive(v) {
- debug("* Passing a WebKitFlags object (with exclusive=true).");
- var flags = new WebKitFlags;
- flags.create = true;
- flags.exclusive = true;
-
- // This should fail.
- fileSystem.root.getFile(testFileName, flags, errorCallback, runNextTest);
+function runObjectTest(v) {
+ // WebKitFlags no longer has a visible constructor.
+ if (window.WebKitFlags)
+ throw "There should be no constructor for WebKitFlags!";
+ runNextTest();
}
function runJSONTest(v) {