summaryrefslogtreecommitdiffstats
path: root/content
diff options
context:
space:
mode:
authorjsbell@chromium.org <jsbell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-25 00:15:54 +0000
committerjsbell@chromium.org <jsbell@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-25 00:15:54 +0000
commitf9cc7b470d52d2ec5322ea7286a618df1536bed9 (patch)
tree102a29bb6de0c3100f8709232ded8ec4817f7778 /content
parentdb36f36531fb10a46634ffc78a08fe17fdd039a1 (diff)
downloadchromium_src-f9cc7b470d52d2ec5322ea7286a618df1536bed9.zip
chromium_src-f9cc7b470d52d2ec5322ea7286a618df1536bed9.tar.gz
chromium_src-f9cc7b470d52d2ec5322ea7286a618df1536bed9.tar.bz2
Prep for landing WK76487
The patch for WebKit 76487 introduces NullType to the WebKit/Chromium WebIDBKey API to support calls that yield null WebCore::IDBKey pointers, which are subtly distinct in the spec from "invalid" results (IDBKey of InvalidType). This patch allows Chromium to build and pass tests with and without that WebKit patch, although some Indexed DB functionality will be broken until the subsequent Chromium patch (https://chromiumcodereview.appspot.com/9212038/) lands which updates test results and updates the IndexedDBKey to match the WebKit semantics. BUG=110956 TEST= Review URL: https://chromiumcodereview.appspot.com/9117040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@118952 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r--content/browser/in_process_webkit/indexed_db_browsertest.cc9
-rw-r--r--content/browser/indexed_db/idbbindingutilities_browsertest.cc3
-rw-r--r--content/common/indexed_db/indexed_db_key.cc5
-rw-r--r--content/common/indexed_db/indexed_db_param_traits.cc8
4 files changed, 19 insertions, 6 deletions
diff --git a/content/browser/in_process_webkit/indexed_db_browsertest.cc b/content/browser/in_process_webkit/indexed_db_browsertest.cc
index 09531283..4693b3b 100644
--- a/content/browser/in_process_webkit/indexed_db_browsertest.cc
+++ b/content/browser/in_process_webkit/indexed_db_browsertest.cc
@@ -60,16 +60,19 @@ class IndexedDBBrowserTest : public InProcessBrowserTest {
}
};
-IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, CursorTest) {
+// TODO(jsbell): Disabled to land WK76487; http://crbug.com/110956 has fix.
+IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_CursorTest) {
SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_test.html"))));
}
-IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, CursorTestIncognito) {
+// TODO(jsbell): Disabled to land WK76487; http://crbug.com/110956 has fix.
+IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_CursorTestIncognito) {
SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_test.html"))),
true /* incognito */);
}
-IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, CursorPrefetch) {
+// TODO(jsbell): Disabled to land WK76487; http://crbug.com/110956 has fix.
+IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_CursorPrefetch) {
SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_prefetch.html"))));
}
diff --git a/content/browser/indexed_db/idbbindingutilities_browsertest.cc b/content/browser/indexed_db/idbbindingutilities_browsertest.cc
index b264c24..0793e0b 100644
--- a/content/browser/indexed_db/idbbindingutilities_browsertest.cc
+++ b/content/browser/indexed_db/idbbindingutilities_browsertest.cc
@@ -37,7 +37,8 @@ class ScopedShutdownWebKit {
};
// Sanity test, check the function call directly outside the sandbox.
-TEST(IDBKeyPathWithoutSandbox, Value) {
+// TODO(jsbell): Disabled to land WK76487; http://crbug.com/110956 has fix.
+TEST(IDBKeyPathWithoutSandbox, DISABLED_Value) {
content::WebKitPlatformSupportImpl webkit_platform_support;
WebKit::initialize(&webkit_platform_support);
ScopedShutdownWebKit shutdown_webkit;
diff --git a/content/common/indexed_db/indexed_db_key.cc b/content/common/indexed_db/indexed_db_key.cc
index dd17e81..1b9491d 100644
--- a/content/common/indexed_db/indexed_db_key.cc
+++ b/content/common/indexed_db/indexed_db_key.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -72,6 +72,9 @@ IndexedDBKey::operator WebIDBKey() const {
case WebIDBKey::NumberType:
return WebIDBKey::createNumber(number_);
case WebIDBKey::InvalidType:
+ default:
+ // TODO(jsbell): Remove "default" label once WebKit bug 76487 has rolled.
+ // http://crbug.com/110956
return WebIDBKey::createInvalid();
}
NOTREACHED();
diff --git a/content/common/indexed_db/indexed_db_param_traits.cc b/content/common/indexed_db/indexed_db_param_traits.cc
index ac3d20f..af33b1d 100644
--- a/content/common/indexed_db/indexed_db_param_traits.cc
+++ b/content/common/indexed_db/indexed_db_param_traits.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -62,6 +62,9 @@ void ParamTraits<IndexedDBKey>::Write(Message* m, const param_type& p) {
WriteParam(m, p.number());
return;
case WebKit::WebIDBKey::InvalidType:
+ default:
+ // TODO(jsbell): Remove "default" label once WebKit bug 76487 has rolled.
+ // http://crbug.com/110956
return;
}
NOTREACHED();
@@ -108,6 +111,9 @@ bool ParamTraits<IndexedDBKey>::Read(const Message* m,
return true;
}
case WebKit::WebIDBKey::InvalidType:
+ default:
+ // TODO(jsbell): Remove "default" label once WebKit bug 76487 has rolled.
+ // http://crbug.com/110956
r->SetInvalid();
return true;
}