| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "components/omnibox/browser/search_provider.h" | 5 #include "components/omnibox/browser/search_provider.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.h" | 24 #include "chrome/browser/autocomplete/chrome_autocomplete_scheme_classifier.h" |
| 25 #include "chrome/browser/history/history_service_factory.h" | 25 #include "chrome/browser/history/history_service_factory.h" |
| 26 #include "chrome/browser/search_engines/template_url_service_factory.h" | 26 #include "chrome/browser/search_engines/template_url_service_factory.h" |
| 27 #include "chrome/browser/signin/account_tracker_service_factory.h" | 27 #include "chrome/browser/signin/account_tracker_service_factory.h" |
| 28 #include "chrome/browser/signin/signin_manager_factory.h" | 28 #include "chrome/browser/signin/signin_manager_factory.h" |
| 29 #include "chrome/browser/sync/profile_sync_service_factory.h" | 29 #include "chrome/browser/sync/profile_sync_service_factory.h" |
| 30 #include "chrome/common/chrome_switches.h" | 30 #include "chrome/common/chrome_switches.h" |
| 31 #include "chrome/common/pref_names.h" | 31 #include "chrome/common/pref_names.h" |
| 32 #include "chrome/test/base/testing_browser_process.h" | 32 #include "chrome/test/base/testing_browser_process.h" |
| 33 #include "chrome/test/base/testing_profile.h" | 33 #include "chrome/test/base/testing_profile.h" |
| 34 #include "components/browser_sync/browser/profile_sync_service.h" | 34 #include "components/browser_sync/profile_sync_service.h" |
| 35 #include "components/google/core/browser/google_switches.h" | 35 #include "components/google/core/browser/google_switches.h" |
| 36 #include "components/history/core/browser/history_service.h" | 36 #include "components/history/core/browser/history_service.h" |
| 37 #include "components/metrics/proto/omnibox_event.pb.h" | 37 #include "components/metrics/proto/omnibox_event.pb.h" |
| 38 #include "components/omnibox/browser/autocomplete_controller.h" | 38 #include "components/omnibox/browser/autocomplete_controller.h" |
| 39 #include "components/omnibox/browser/autocomplete_input.h" | 39 #include "components/omnibox/browser/autocomplete_input.h" |
| 40 #include "components/omnibox/browser/autocomplete_match.h" | 40 #include "components/omnibox/browser/autocomplete_match.h" |
| 41 #include "components/omnibox/browser/autocomplete_provider.h" | 41 #include "components/omnibox/browser/autocomplete_provider.h" |
| 42 #include "components/omnibox/browser/autocomplete_provider_listener.h" | 42 #include "components/omnibox/browser/autocomplete_provider_listener.h" |
| 43 #include "components/omnibox/browser/history_url_provider.h" | 43 #include "components/omnibox/browser/history_url_provider.h" |
| 44 #include "components/omnibox/browser/omnibox_field_trial.h" | 44 #include "components/omnibox/browser/omnibox_field_trial.h" |
| (...skipping 3469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3514 } | 3514 } |
| 3515 | 3515 |
| 3516 TEST_F(SearchProviderTest, DoesNotProvideOnFocus) { | 3516 TEST_F(SearchProviderTest, DoesNotProvideOnFocus) { |
| 3517 AutocompleteInput input( | 3517 AutocompleteInput input( |
| 3518 base::ASCIIToUTF16("f"), base::string16::npos, std::string(), GURL(), | 3518 base::ASCIIToUTF16("f"), base::string16::npos, std::string(), GURL(), |
| 3519 metrics::OmniboxEventProto::INVALID_SPEC, false, true, true, true, true, | 3519 metrics::OmniboxEventProto::INVALID_SPEC, false, true, true, true, true, |
| 3520 ChromeAutocompleteSchemeClassifier(&profile_)); | 3520 ChromeAutocompleteSchemeClassifier(&profile_)); |
| 3521 provider_->Start(input, false); | 3521 provider_->Start(input, false); |
| 3522 EXPECT_TRUE(provider_->matches().empty()); | 3522 EXPECT_TRUE(provider_->matches().empty()); |
| 3523 } | 3523 } |
| OLD | NEW |