OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 /** @fileoverview Suite of tests for site-list. */ | 5 /** @fileoverview Suite of tests for site-list. */ |
6 cr.define('site_list', function() { | 6 cr.define('site_list', function() { |
7 function registerTests() { | 7 function registerTests() { |
8 suite('SiteList', function() { | 8 suite('SiteList', function() { |
9 /** | 9 /** |
10 * A site list element created before each test. | 10 * A site list element created before each test. |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 }, | 51 }, |
52 { | 52 { |
53 embeddingOrigin: 'https://foo-block.com:443', | 53 embeddingOrigin: 'https://foo-block.com:443', |
54 origin: 'https://foo-block.com:443', | 54 origin: 'https://foo-block.com:443', |
55 setting: 'block', | 55 setting: 'block', |
56 source: 'preference', | 56 source: 'preference', |
57 }, | 57 }, |
58 ], | 58 ], |
59 images: [], | 59 images: [], |
60 javascript: [], | 60 javascript: [], |
61 keygen: [], | |
62 mic: [], | 61 mic: [], |
63 notifications: [], | 62 notifications: [], |
64 plugins: [], | 63 plugins: [], |
65 popups: [], | 64 popups: [], |
66 unsandboxed_plugins: [], | 65 unsandboxed_plugins: [], |
67 } | 66 } |
68 }; | 67 }; |
69 | 68 |
70 /** | 69 /** |
71 * An example pref with mixed schemes (present and absent). | 70 * An example pref with mixed schemes (present and absent). |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 ], | 140 ], |
142 images: [], | 141 images: [], |
143 javascript: [ | 142 javascript: [ |
144 { | 143 { |
145 origin: 'https://[*.]foo.com', | 144 origin: 'https://[*.]foo.com', |
146 embeddingOrigin: '*', | 145 embeddingOrigin: '*', |
147 setting: 'allow', | 146 setting: 'allow', |
148 source: 'preference', | 147 source: 'preference', |
149 }, | 148 }, |
150 ], | 149 ], |
151 keygen: [], | |
152 mic: [], | 150 mic: [], |
153 notifications: [], | 151 notifications: [], |
154 plugins: [], | 152 plugins: [], |
155 popups: [], | 153 popups: [], |
156 unsandboxed_plugins: [], | 154 unsandboxed_plugins: [], |
157 } | 155 } |
158 }; | 156 }; |
159 | 157 |
160 /** | 158 /** |
161 * An example pref with multiple categories and multiple allow/block | 159 * An example pref with multiple categories and multiple allow/block |
(...skipping 15 matching lines...) Expand all Loading... |
177 }, | 175 }, |
178 { | 176 { |
179 embeddingOrigin: 'https://bar.com', | 177 embeddingOrigin: 'https://bar.com', |
180 origin: 'https://bar.com', | 178 origin: 'https://bar.com', |
181 setting: 'block', | 179 setting: 'block', |
182 source: 'preference', | 180 source: 'preference', |
183 }, | 181 }, |
184 ], | 182 ], |
185 images: [], | 183 images: [], |
186 javascript: [], | 184 javascript: [], |
187 keygen: [], | |
188 mic: [], | 185 mic: [], |
189 notifications: [ | 186 notifications: [ |
190 { | 187 { |
191 embeddingOrigin: 'https://google.com', | 188 embeddingOrigin: 'https://google.com', |
192 origin: 'https://google.com', | 189 origin: 'https://google.com', |
193 setting: 'block', | 190 setting: 'block', |
194 source: 'preference', | 191 source: 'preference', |
195 }, | 192 }, |
196 { | 193 { |
197 embeddingOrigin: 'https://bar.com', | 194 embeddingOrigin: 'https://bar.com', |
(...skipping 669 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
867 assertEquals(settings.ContentSettingsTypes.JAVASCRIPT, args[2]); | 864 assertEquals(settings.ContentSettingsTypes.JAVASCRIPT, args[2]); |
868 assertEquals('allow', args[3]); | 865 assertEquals('allow', args[3]); |
869 }); | 866 }); |
870 }); | 867 }); |
871 }); | 868 }); |
872 } | 869 } |
873 return { | 870 return { |
874 registerTests: registerTests, | 871 registerTests: registerTests, |
875 }; | 872 }; |
876 }); | 873 }); |
OLD | NEW |