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

Side by Side Diff: chrome/browser/autocomplete/shortcuts_backend_unittest.cc

Issue 368273011: Revert of Componentize TemplateURLService (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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
OLDNEW
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 "chrome/browser/autocomplete/shortcuts_backend.h" 5 #include "chrome/browser/autocomplete/shortcuts_backend.h"
6 6
7 #include "base/files/scoped_temp_dir.h" 7 #include "base/files/scoped_temp_dir.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
11 #include "base/strings/utf_string_conversions.h" 11 #include "base/strings/utf_string_conversions.h"
12 #include "chrome/browser/autocomplete/shortcuts_backend_factory.h" 12 #include "chrome/browser/autocomplete/shortcuts_backend_factory.h"
13 #include "chrome/browser/history/shortcuts_database.h" 13 #include "chrome/browser/history/shortcuts_database.h"
14 #include "chrome/browser/search_engines/template_url_service.h"
14 #include "chrome/browser/search_engines/template_url_service_factory.h" 15 #include "chrome/browser/search_engines/template_url_service_factory.h"
15 #include "chrome/test/base/testing_profile.h" 16 #include "chrome/test/base/testing_profile.h"
16 #include "chrome/test/base/ui_test_utils.h" 17 #include "chrome/test/base/ui_test_utils.h"
17 #include "components/search_engines/template_url_service.h"
18 #include "content/public/test/test_browser_thread.h" 18 #include "content/public/test/test_browser_thread.h"
19 #include "sql/statement.h" 19 #include "sql/statement.h"
20 20
21 #include "testing/gtest/include/gtest/gtest.h" 21 #include "testing/gtest/include/gtest/gtest.h"
22 22
23 23
24 // ShortcutsBackendTest ------------------------------------------------------- 24 // ShortcutsBackendTest -------------------------------------------------------
25 25
26 class ShortcutsBackendTest : public testing::Test, 26 class ShortcutsBackendTest : public testing::Test,
27 public ShortcutsBackend::ShortcutsBackendObserver { 27 public ShortcutsBackend::ShortcutsBackendObserver {
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 ASSERT_TRUE(shortcut4_iter != shortcuts_map().end()); 313 ASSERT_TRUE(shortcut4_iter != shortcuts_map().end());
314 EXPECT_EQ(shortcut4.id, shortcut4_iter->second.id); 314 EXPECT_EQ(shortcut4.id, shortcut4_iter->second.id);
315 315
316 history::ShortcutsDatabase::ShortcutIDs deleted_ids; 316 history::ShortcutsDatabase::ShortcutIDs deleted_ids;
317 deleted_ids.push_back(shortcut3.id); 317 deleted_ids.push_back(shortcut3.id);
318 deleted_ids.push_back(shortcut4.id); 318 deleted_ids.push_back(shortcut4.id);
319 EXPECT_TRUE(DeleteShortcutsWithIDs(deleted_ids)); 319 EXPECT_TRUE(DeleteShortcutsWithIDs(deleted_ids));
320 320
321 ASSERT_EQ(0U, shortcuts_map().size()); 321 ASSERT_EQ(0U, shortcuts_map().size());
322 } 322 }
OLDNEW
« no previous file with comments | « chrome/browser/autocomplete/search_provider_unittest.cc ('k') | chrome/browser/autocomplete/zero_suggest_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698