1# Copyright 2015 The Chromium OS Authors. All rights reserved. 2# Use of this source code is governed by a BSD-style license that can be 3# found in the LICENSE file. 4 5AUTHOR = 'scunningham' 6NAME = 'policy_JavaScriptBlockedForUrls' 7TIME = 'SHORT' 8TEST_CATEGORY = 'General' 9TEST_CLASS = 'enterprise' 10TEST_TYPE = 'client' 11 12DOC = ''' 13Verify effects of JavaScriptBlockedForUrls policy on client behavior. 14 15This test verifies the effect of the JavaScriptBlockedForUrls user policy on 16Chrome OS client behavior when user policy DefaultJavaScriptSetting=1, meaning 17allow JavaScript on all pages except for those in JavaScriptBlockedForUrls. 18 19It exercises a range of policy values using four unique named test cases: 20NotSet_Allow, SingleUrl_Block, MultipleUrls_Allow, and MultipleUrls_Block. 21See the test file for a full description of what each test case does. 22 23In general, a test shall pass if the browser blocks JavaScript execution only 24on a test page with a URL that matches one or more of the URL patterns listed 25in JavaScriptBlockedForUrls. A test shall fail if the browser allows execution 26on a page where it should be blocked, or blocks execution on a page where it 27should be allowed. 28 29''' 30 31args_dict = utils.args_to_dict(args) 32 33job.run_test('policy_JavaScriptBlockedForUrls', **args_dict) 34