Chromium Code Reviews| Index: chrome/test/data/extensions/api_test/preference/standard/test.js |
| diff --git a/chrome/test/data/extensions/api_test/preference/standard/test.js b/chrome/test/data/extensions/api_test/preference/standard/test.js |
| index 8fdff4505a9e1bb2275280ed3131d410cfa6411e..07c1cb82567b0dafe26288bfe128ee8f142ab746 100644 |
| --- a/chrome/test/data/extensions/api_test/preference/standard/test.js |
| +++ b/chrome/test/data/extensions/api_test/preference/standard/test.js |
| @@ -3,15 +3,14 @@ |
| // found in the LICENSE file. |
| // Preferences API test |
| -// Run with browser_tests --gtest_filter=ExtensionApiTest.PreferenceApi |
| +// Run with browser_tests --gtest_filter=ExtensionPreferenceApiTest.Standard |
| +var pn = chrome.privacy.network; |
| var preferences_to_test = [ |
| { |
| root: chrome.privacy.network, |
| preferences: [ |
| - 'networkPredictionEnabled', |
| - 'webRTCMultipleRoutesEnabled', |
| - 'webRTCNonProxiedUdpEnabled' |
| + 'networkPredictionEnabled' |
| ] |
| }, |
| { |
| @@ -42,9 +41,7 @@ var preferences_to_test = [ |
| // Some preferences are only present on certain platforms or are hidden |
| // behind flags and might not be present when this test runs. |
| var possibly_missing_preferences = new Set([ |
| - 'protectedContentEnabled', // Windows/ChromeOS only |
| - 'webRTCMultipleRoutesEnabled', // requires ENABLE_WEBRTC=1 |
| - 'webRTCNonProxiedUdpEnabled' // requires ENABLE_WEBRTC=1 |
| + 'protectedContentEnabled' // Windows/ChromeOS only |
| ]); |
| function expect(expected, message) { |
| @@ -86,5 +83,27 @@ chrome.test.runTests([ |
| preferences_to_test[i].preferences.forEach( |
| prefSetter.bind(preferences_to_test[i].root)); |
| } |
| + }, |
| + function getWebRTCIPHandlingPolicy() { |
| + if (pn.webRTCIPHandlingPolicy == undefined) { |
| + chrome.test.callbackPass(); |
| + return; |
| + } |
| + pn.webRTCIPHandlingPolicy.get( |
| + {}, |
| + expect({ 'value': |
|
Devlin
2015/10/27 16:13:31
nit: no need for quotes around keys.
guoweis_left_chromium
2015/10/27 20:32:00
Done.
|
| + chrome.privacy.IPHandlingPolicy.DEFAULT_PUBLIC_INTERFACE_ONLY, |
| + 'levelOfControl': "controllable_by_this_extension" }, |
| + "should receive default_public_interface_only.")); |
| + }, |
| + function setWebRTCIPHandlingPolicy() { |
| + if (pn.webRTCIPHandlingPolicy == undefined) { |
| + chrome.test.callbackPass(); |
| + return; |
| + } |
| + pn.webRTCIPHandlingPolicy.set( |
| + { 'value': |
| + chrome.privacy.IPHandlingPolicy.DISABLE_NON_PROXIED_UDP}, |
| + chrome.test.callbackPass()); |
|
Devlin
2015/10/27 16:13:31
What does this actually test? It's not verifying
guoweis_left_chromium
2015/10/27 20:32:00
Done.
|
| } |
| ]); |