| 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 "base/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/message_loop.h" | 6 #include "base/message_loop.h" |
| 7 #include "base/path_service.h" | 7 #include "base/path_service.h" |
| 8 #include "base/scoped_temp_dir.h" | 8 #include "base/scoped_temp_dir.h" |
| 9 #include "base/stringprintf.h" | 9 #include "base/stringprintf.h" |
| 10 #include "base/time.h" | 10 #include "base/time.h" |
| 11 #include "base/utf_string_conversions.h" | 11 #include "base/utf_string_conversions.h" |
| 12 #include "chrome/browser/history/shortcuts_backend.h" | 12 #include "chrome/browser/history/shortcuts_backend.h" |
| 13 #include "chrome/browser/history/shortcuts_database.h" | 13 #include "chrome/browser/history/shortcuts_database.h" |
| 14 #include "chrome/common/guid.h" | |
| 15 #include "content/public/test/test_browser_thread.h" | 14 #include "content/public/test/test_browser_thread.h" |
| 16 #include "sql/statement.h" | 15 #include "sql/statement.h" |
| 17 | 16 |
| 18 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
| 19 | 18 |
| 20 using content::BrowserThread; | 19 using content::BrowserThread; |
| 21 | 20 |
| 22 namespace history { | 21 namespace history { |
| 23 | 22 |
| 24 const base::TimeDelta kMaxRequestWaitTimeout = base::TimeDelta::FromSeconds(1); | 23 const base::TimeDelta kMaxRequestWaitTimeout = base::TimeDelta::FromSeconds(1); |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 std::vector<std::string> deleted_ids; | 154 std::vector<std::string> deleted_ids; |
| 156 deleted_ids.push_back(shortcut3.id); | 155 deleted_ids.push_back(shortcut3.id); |
| 157 deleted_ids.push_back(shortcut4.id); | 156 deleted_ids.push_back(shortcut4.id); |
| 158 | 157 |
| 159 EXPECT_TRUE(backend_->DeleteShortcutsWithIds(deleted_ids)); | 158 EXPECT_TRUE(backend_->DeleteShortcutsWithIds(deleted_ids)); |
| 160 | 159 |
| 161 ASSERT_EQ(0U, shortcuts.size()); | 160 ASSERT_EQ(0U, shortcuts.size()); |
| 162 } | 161 } |
| 163 | 162 |
| 164 } // namespace history | 163 } // namespace history |
| OLD | NEW |