Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(405)

Side by Side Diff: content/browser/in_process_webkit/indexed_db_browsertest.cc

Issue 6961017: Add a browser test for IndexedDB+LevelDB. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/file_path.h" 6 #include "base/file_path.h"
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/scoped_temp_dir.h" 9 #include "base/scoped_temp_dir.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 if (result != "pass") { 42 if (result != "pass") {
43 std::string js_result; 43 std::string js_result;
44 ASSERT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractString( 44 ASSERT_TRUE(ui_test_utils::ExecuteJavaScriptAndExtractString(
45 browser()->GetSelectedTabContents()->render_view_host(), L"", 45 browser()->GetSelectedTabContents()->render_view_host(), L"",
46 L"window.domAutomationController.send(getLog())", &js_result)); 46 L"window.domAutomationController.send(getLog())", &js_result));
47 FAIL() << "Failed: " << js_result; 47 FAIL() << "Failed: " << js_result;
48 } 48 }
49 } 49 }
50 }; 50 };
51 51
52 class IndexedDBLevelDBBrowserTest : public IndexedDBBrowserTest {
53 public:
54 virtual void SetUpCommandLine(CommandLine* command_line) {
55 command_line->AppendSwitch(switches::kLevelDBIndexedDatabase);
56 }
57 };
58
52 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, CursorTest) { 59 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, CursorTest) {
53 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_test.html")))); 60 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_test.html"))));
54 } 61 }
55 62
63 IN_PROC_BROWSER_TEST_F(IndexedDBLevelDBBrowserTest, CursorTest) {
64 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("cursor_test.html"))));
65 }
66
56 // Flaky: http://crbug.com/70773 67 // Flaky: http://crbug.com/70773
57 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_IndexTest) { 68 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_IndexTest) {
58 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("index_test.html")))); 69 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("index_test.html"))));
59 } 70 }
60 71
61 // Flaky: http://crbug.com/70773 72 // Flaky: http://crbug.com/70773
62 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_KeyPathTest) { 73 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTest, DISABLED_KeyPathTest) {
63 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("key_path_test.html")))); 74 SimpleTest(testUrl(FilePath(FILE_PATH_LITERAL("key_path_test.html"))));
64 } 75 }
65 76
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 virtual void SetUpCommandLine(CommandLine* command_line) { 144 virtual void SetUpCommandLine(CommandLine* command_line) {
134 command_line->AppendSwitchASCII(switches::kJavaScriptFlags, "--expose-gc"); 145 command_line->AppendSwitchASCII(switches::kJavaScriptFlags, "--expose-gc");
135 } 146 }
136 }; 147 };
137 148
138 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestWithGCExposed, 149 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestWithGCExposed,
139 DatabaseCallbacksTest) { 150 DatabaseCallbacksTest) {
140 SimpleTest( 151 SimpleTest(
141 testUrl(FilePath(FILE_PATH_LITERAL("database_callbacks_first.html")))); 152 testUrl(FilePath(FILE_PATH_LITERAL("database_callbacks_first.html"))));
142 } 153 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698