OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/content_settings/core/browser/content_settings_utils.h" | 5 #include "components/content_settings/core/browser/content_settings_utils.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <string> | 9 #include <string> |
8 | 10 |
| 11 #include "base/macros.h" |
9 #include "components/content_settings/core/test/content_settings_test_utils.h" | 12 #include "components/content_settings/core/test/content_settings_test_utils.h" |
10 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
11 | 14 |
12 namespace { | 15 namespace { |
13 | 16 |
14 const char* const kContentSettingNames[] = { | 17 const char* const kContentSettingNames[] = { |
15 "default", | 18 "default", |
16 "allow", | 19 "allow", |
17 "block", | 20 "block", |
18 "ask", | 21 "ask", |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 if (i == 0) { | 77 if (i == 0) { |
75 EXPECT_FALSE(content_settings::ContentSettingFromString( | 78 EXPECT_FALSE(content_settings::ContentSettingFromString( |
76 kContentSettingNames[i], &converted_setting)); | 79 kContentSettingNames[i], &converted_setting)); |
77 } else { | 80 } else { |
78 EXPECT_TRUE(content_settings::ContentSettingFromString( | 81 EXPECT_TRUE(content_settings::ContentSettingFromString( |
79 kContentSettingNames[i], &converted_setting)); | 82 kContentSettingNames[i], &converted_setting)); |
80 } | 83 } |
81 EXPECT_EQ(setting, converted_setting); | 84 EXPECT_EQ(setting, converted_setting); |
82 } | 85 } |
83 } | 86 } |
OLD | NEW |