OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <stddef.h> | 5 #include <stddef.h> |
6 #include <stdint.h> | 6 #include <stdint.h> |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
307 }; | 307 }; |
308 | 308 |
309 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestWithGCExposed, | 309 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestWithGCExposed, |
310 DatabaseCallbacksTest) { | 310 DatabaseCallbacksTest) { |
311 SimpleTest(GetTestUrl("indexeddb", "database_callbacks_first.html")); | 311 SimpleTest(GetTestUrl("indexeddb", "database_callbacks_first.html")); |
312 } | 312 } |
313 | 313 |
314 static void CopyLevelDBToProfile(Shell* shell, | 314 static void CopyLevelDBToProfile(Shell* shell, |
315 scoped_refptr<IndexedDBContextImpl> context, | 315 scoped_refptr<IndexedDBContextImpl> context, |
316 const std::string& test_directory) { | 316 const std::string& test_directory) { |
317 DCHECK(context->TaskRunner()->RunsTasksOnCurrentThread()); | 317 DCHECK(context->TaskRunner()->RunsTasksInCurrentSequence()); |
318 base::FilePath leveldb_dir(FILE_PATH_LITERAL("file__0.indexeddb.leveldb")); | 318 base::FilePath leveldb_dir(FILE_PATH_LITERAL("file__0.indexeddb.leveldb")); |
319 base::FilePath test_data_dir = | 319 base::FilePath test_data_dir = |
320 GetTestFilePath("indexeddb", test_directory.c_str()).Append(leveldb_dir); | 320 GetTestFilePath("indexeddb", test_directory.c_str()).Append(leveldb_dir); |
321 base::FilePath dest = context->data_path().Append(leveldb_dir); | 321 base::FilePath dest = context->data_path().Append(leveldb_dir); |
322 // If we don't create the destination directory first, the contents of the | 322 // If we don't create the destination directory first, the contents of the |
323 // leveldb directory are copied directly into profile/IndexedDB instead of | 323 // leveldb directory are copied directly into profile/IndexedDB instead of |
324 // profile/IndexedDB/file__0.xxx/ | 324 // profile/IndexedDB/file__0.xxx/ |
325 ASSERT_TRUE(base::CreateDirectory(dest)); | 325 ASSERT_TRUE(base::CreateDirectory(dest)); |
326 const bool kRecursive = true; | 326 const bool kRecursive = true; |
327 ASSERT_TRUE(base::CopyDirectory(test_data_dir, | 327 ASSERT_TRUE(base::CopyDirectory(test_data_dir, |
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
858 command_line->AppendSwitch(switches::kSingleProcess); | 858 command_line->AppendSwitch(switches::kSingleProcess); |
859 } | 859 } |
860 }; | 860 }; |
861 | 861 |
862 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestSingleProcess, | 862 IN_PROC_BROWSER_TEST_F(IndexedDBBrowserTestSingleProcess, |
863 RenderThreadShutdownTest) { | 863 RenderThreadShutdownTest) { |
864 SimpleTest(GetTestUrl("indexeddb", "shutdown_with_requests.html")); | 864 SimpleTest(GetTestUrl("indexeddb", "shutdown_with_requests.html")); |
865 } | 865 } |
866 | 866 |
867 } // namespace content | 867 } // namespace content |
OLD | NEW |