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 "base/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/files/scoped_temp_dir.h" |
6 #include "base/memory/scoped_vector.h" | 7 #include "base/memory/scoped_vector.h" |
7 #include "base/scoped_temp_dir.h" | |
8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
9 #include "chrome/browser/search_engines/search_terms_data.h" | 9 #include "chrome/browser/search_engines/search_terms_data.h" |
10 #include "chrome/browser/search_engines/template_url.h" | 10 #include "chrome/browser/search_engines/template_url.h" |
| 11 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" |
11 #include "chrome/browser/search_engines/template_url_service.h" | 12 #include "chrome/browser/search_engines/template_url_service.h" |
12 #include "chrome/browser/search_engines/template_url_prepopulate_data.h" | |
13 #include "chrome/common/pref_names.h" | 13 #include "chrome/common/pref_names.h" |
14 #include "chrome/test/base/testing_pref_service.h" | 14 #include "chrome/test/base/testing_pref_service.h" |
15 #include "chrome/test/base/testing_profile.h" | 15 #include "chrome/test/base/testing_profile.h" |
16 #include "grit/generated_resources.h" | 16 #include "grit/generated_resources.h" |
17 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
18 #include "ui/base/l10n/l10n_util.h" | 18 #include "ui/base/l10n/l10n_util.h" |
19 | 19 |
20 typedef testing::Test TemplateURLPrepopulateDataTest; | 20 typedef testing::Test TemplateURLPrepopulateDataTest; |
21 | 21 |
22 const int kCountryIds[] = { | 22 const int kCountryIds[] = { |
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
254 | 254 |
255 TEST(TemplateURLPrepopulateDataTest, GetLogoURLInvalid) { | 255 TEST(TemplateURLPrepopulateDataTest, GetLogoURLInvalid) { |
256 TemplateURLData data; | 256 TemplateURLData data; |
257 data.SetURL("http://invalid:search:url/"); | 257 data.SetURL("http://invalid:search:url/"); |
258 TemplateURL turl(NULL, data); | 258 TemplateURL turl(NULL, data); |
259 GURL logo_url = TemplateURLPrepopulateData::GetLogoURL( | 259 GURL logo_url = TemplateURLPrepopulateData::GetLogoURL( |
260 turl, TemplateURLPrepopulateData::LOGO_100_PERCENT); | 260 turl, TemplateURLPrepopulateData::LOGO_100_PERCENT); |
261 | 261 |
262 EXPECT_TRUE(logo_url.is_empty()); | 262 EXPECT_TRUE(logo_url.is_empty()); |
263 } | 263 } |
OLD | NEW |