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

Side by Side Diff: chrome/browser/search_engines/template_url_service_unittest.cc

Issue 324283003: Move search_terms_data to components/search_engines (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 6 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 "base/bind.h" 5 #include "base/bind.h"
6 #include "base/bind_helpers.h" 6 #include "base/bind_helpers.h"
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_vector.h" 9 #include "base/memory/scoped_vector.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
11 #include "base/strings/string_split.h" 11 #include "base/strings/string_split.h"
12 #include "base/strings/string_util.h" 12 #include "base/strings/string_util.h"
13 #include "base/strings/utf_string_conversions.h" 13 #include "base/strings/utf_string_conversions.h"
14 #include "base/test/mock_time_provider.h" 14 #include "base/test/mock_time_provider.h"
15 #include "base/threading/thread.h" 15 #include "base/threading/thread.h"
16 #include "base/time/time.h" 16 #include "base/time/time.h"
17 #include "chrome/browser/history/history_notifications.h" 17 #include "chrome/browser/history/history_notifications.h"
18 #include "chrome/browser/history/history_service.h" 18 #include "chrome/browser/history/history_service.h"
19 #include "chrome/browser/history/history_service_factory.h" 19 #include "chrome/browser/history/history_service_factory.h"
20 #include "chrome/browser/search_engines/search_host_to_urls_map.h" 20 #include "chrome/browser/search_engines/search_host_to_urls_map.h"
21 #include "chrome/browser/search_engines/search_terms_data.h"
22 #include "chrome/browser/search_engines/template_url.h" 21 #include "chrome/browser/search_engines/template_url.h"
23 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" 22 #include "chrome/browser/search_engines/template_url_prepopulate_data.h"
24 #include "chrome/browser/search_engines/template_url_service.h" 23 #include "chrome/browser/search_engines/template_url_service.h"
25 #include "chrome/browser/search_engines/template_url_service_test_util.h" 24 #include "chrome/browser/search_engines/template_url_service_test_util.h"
25 #include "chrome/browser/search_engines/ui_thread_search_terms_data.h"
26 #include "chrome/browser/webdata/web_data_service_factory.h" 26 #include "chrome/browser/webdata/web_data_service_factory.h"
27 #include "chrome/test/base/testing_profile.h" 27 #include "chrome/test/base/testing_profile.h"
28 #include "components/webdata/common/web_database.h" 28 #include "components/webdata/common/web_database.h"
29 #include "extensions/common/constants.h" 29 #include "extensions/common/constants.h"
30 #include "extensions/common/extension.h" 30 #include "extensions/common/extension.h"
31 #include "extensions/common/manifest_constants.h" 31 #include "extensions/common/manifest_constants.h"
32 #include "testing/gtest/include/gtest/gtest.h" 32 #include "testing/gtest/include/gtest/gtest.h"
33 33
34 using base::ASCIIToUTF16; 34 using base::ASCIIToUTF16;
35 using base::Time; 35 using base::Time;
(...skipping 1522 matching lines...) Expand 10 before | Expand all | Expand 10 after
1558 scoped_ptr<AssociatedExtensionInfo> extension_info( 1558 scoped_ptr<AssociatedExtensionInfo> extension_info(
1559 new AssociatedExtensionInfo); 1559 new AssociatedExtensionInfo);
1560 extension_info->wants_to_be_default_engine = true; 1560 extension_info->wants_to_be_default_engine = true;
1561 extension_info->extension_id = "ext1"; 1561 extension_info->extension_id = "ext1";
1562 model()->AddExtensionControlledTURL(ext_dse, extension_info.Pass()); 1562 model()->AddExtensionControlledTURL(ext_dse, extension_info.Pass());
1563 EXPECT_EQ(ext_dse, model()->GetTemplateURLForKeyword(ASCIIToUTF16("ext1"))); 1563 EXPECT_EQ(ext_dse, model()->GetTemplateURLForKeyword(ASCIIToUTF16("ext1")));
1564 EXPECT_TRUE(model()->is_default_search_managed()); 1564 EXPECT_TRUE(model()->is_default_search_managed());
1565 actual_managed_default = model()->GetDefaultSearchProvider(); 1565 actual_managed_default = model()->GetDefaultSearchProvider();
1566 ExpectSimilar(expected_managed_default.get(), actual_managed_default); 1566 ExpectSimilar(expected_managed_default.get(), actual_managed_default);
1567 } 1567 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698