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 "chrome/browser/autocomplete/history_url_provider.h" | 5 #include "chrome/browser/autocomplete/history_url_provider.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
11 #include "base/path_service.h" | 11 #include "base/path_service.h" |
12 #include "base/string_util.h" | 12 #include "base/string_util.h" |
13 #include "base/utf_string_conversions.h" | 13 #include "base/utf_string_conversions.h" |
14 #include "chrome/browser/autocomplete/autocomplete_match.h" | 14 #include "chrome/browser/autocomplete/autocomplete_match.h" |
15 #include "chrome/browser/autocomplete/history_quick_provider.h" | 15 #include "chrome/browser/autocomplete/history_quick_provider.h" |
16 #include "chrome/browser/history/history.h" | 16 #include "chrome/browser/history/history.h" |
17 #include "chrome/browser/net/url_fixer_upper.h" | 17 #include "chrome/browser/net/url_fixer_upper.h" |
18 #include "chrome/test/base/testing_browser_process.h" | 18 #include "chrome/test/base/testing_browser_process.h" |
19 #include "chrome/test/base/testing_profile.h" | 19 #include "chrome/test/base/testing_profile.h" |
20 #include "content/test/test_browser_thread.h" | 20 #include "content/public/test/test_browser_thread.h" |
21 #include "testing/gtest/include/gtest/gtest.h" | 21 #include "testing/gtest/include/gtest/gtest.h" |
22 | 22 |
23 using base::Time; | 23 using base::Time; |
24 using base::TimeDelta; | 24 using base::TimeDelta; |
25 | 25 |
26 using content::BrowserThread; | 26 using content::BrowserThread; |
27 | 27 |
28 struct TestURLInfo { | 28 struct TestURLInfo { |
29 const char* url; | 29 const char* url; |
30 const char* title; | 30 const char* title; |
(...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
671 "\\@st" | 671 "\\@st" |
672 }; | 672 }; |
673 for (size_t i = 0; i < arraysize(test_cases); ++i) { | 673 for (size_t i = 0; i < arraysize(test_cases); ++i) { |
674 AutocompleteInput input(ASCIIToUTF16(test_cases[i]), string16(), false, | 674 AutocompleteInput input(ASCIIToUTF16(test_cases[i]), string16(), false, |
675 false, true, AutocompleteInput::ALL_MATCHES); | 675 false, true, AutocompleteInput::ALL_MATCHES); |
676 autocomplete_->Start(input, false); | 676 autocomplete_->Start(input, false); |
677 if (!autocomplete_->done()) | 677 if (!autocomplete_->done()) |
678 MessageLoop::current()->Run(); | 678 MessageLoop::current()->Run(); |
679 } | 679 } |
680 } | 680 } |
OLD | NEW |