OLD | NEW |
1 <script> | 1 <script> |
2 // Content settings API test | 2 // Content settings API test |
3 // Run with browser_tests --gtest_filter=ExtensionApiTest.ContentSettings | 3 // Run with browser_tests --gtest_filter=ExtensionApiTest.ContentSettings |
4 | 4 |
5 var cs = chrome.experimental.contentSettings; | 5 var cs = chrome.contentSettings; |
6 var default_content_settings = { | 6 var default_content_settings = { |
7 "cookies": "session_only", | 7 "cookies": "session_only", |
8 "images": "allow", | 8 "images": "allow", |
9 "javascript": "block", | 9 "javascript": "block", |
10 "plugins": "allow", | 10 "plugins": "allow", |
11 "popups": "block", | 11 "popups": "block", |
12 // TODO(bauerb) | 12 // TODO(bauerb) |
13 // "geolocation": "ask", | 13 // "geolocation": "ask", |
14 "notifications": "ask" | 14 "notifications": "ask" |
15 }; | 15 }; |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 'setting': 'block' | 83 'setting': 'block' |
84 }, chrome.test.callbackFail("Specific paths are not allowed.")); | 84 }, chrome.test.callbackFail("Specific paths are not allowed.")); |
85 cs.javascript.set({ | 85 cs.javascript.set({ |
86 'primaryPattern': 'http://example.com/*', | 86 'primaryPattern': 'http://example.com/*', |
87 'secondaryPattern': 'file:///home/hansmoleman/*', | 87 'secondaryPattern': 'file:///home/hansmoleman/*', |
88 'setting': 'allow' | 88 'setting': 'allow' |
89 }, chrome.test.callbackFail("Path wildcards in file URL patterns are not all
owed.")); | 89 }, chrome.test.callbackFail("Path wildcards in file URL patterns are not all
owed.")); |
90 } | 90 } |
91 ]); | 91 ]); |
92 </script> | 92 </script> |
OLD | NEW |