| 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 #ifndef CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ | 5 #ifndef CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ |
| 6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ | 6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 | 79 |
| 80 // Returns the TemplateURLService. | 80 // Returns the TemplateURLService. |
| 81 TemplateURLService* model() const; | 81 TemplateURLService* model() const; |
| 82 | 82 |
| 83 // Returns the TestingProfile. | 83 // Returns the TestingProfile. |
| 84 TestingProfile* profile() const; | 84 TestingProfile* profile() const; |
| 85 | 85 |
| 86 // Starts an I/O thread. | 86 // Starts an I/O thread. |
| 87 void StartIOThread(); | 87 void StartIOThread(); |
| 88 | 88 |
| 89 // Runs all pending tasks on the UI loop. |
| 90 void PumpLoop(); |
| 91 |
| 89 private: | 92 private: |
| 90 MessageLoopForUI message_loop_; | 93 MessageLoopForUI message_loop_; |
| 91 // Needed to make the DeleteOnUIThread trait of WebDataService work | 94 // Needed to make the DeleteOnUIThread trait of WebDataService work |
| 92 // properly. | 95 // properly. |
| 93 content::TestBrowserThread ui_thread_; | 96 content::TestBrowserThread ui_thread_; |
| 94 scoped_ptr<TemplateURLServiceTestingProfile> profile_; | 97 scoped_ptr<TemplateURLServiceTestingProfile> profile_; |
| 95 scoped_ptr<TestingTemplateURLService> model_; | 98 scoped_ptr<TestingTemplateURLService> model_; |
| 96 int changed_count_; | 99 int changed_count_; |
| 97 | 100 |
| 98 DISALLOW_COPY_AND_ASSIGN(TemplateURLServiceTestUtil); | 101 DISALLOW_COPY_AND_ASSIGN(TemplateURLServiceTestUtil); |
| 99 }; | 102 }; |
| 100 | 103 |
| 101 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ | 104 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_SERVICE_TEST_UTIL_H_ |
| OLD | NEW |