Home | History | Annotate | Download | only in policy_JavaScriptBlockedForUrls
      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 
      5 AUTHOR = 'scunningham'
      6 NAME = 'policy_JavaScriptBlockedForUrls'
      7 TIME = 'SHORT'
      8 TEST_CATEGORY = 'General'
      9 TEST_CLASS = 'enterprise'
     10 TEST_TYPE = 'client'
     11 
     12 DOC = '''
     13 Verify effects of JavaScriptBlockedForUrls policy on client behavior.
     14 
     15 This test verifies the effect of the JavaScriptBlockedForUrls user policy on
     16 Chrome OS client behavior when user policy DefaultJavaScriptSetting=1, meaning
     17 allow JavaScript on all pages except for those in JavaScriptBlockedForUrls.
     18 
     19 It exercises a range of policy values using four unique named test cases:
     20 NotSet_Allow, SingleUrl_Block, MultipleUrls_Allow, and MultipleUrls_Block.
     21 See the test file for a full description of what each test case does.
     22 
     23 In general, a test shall pass if the browser blocks JavaScript execution only
     24 on a test page with a URL that matches one or more of the URL patterns listed
     25 in JavaScriptBlockedForUrls. A test shall fail if the browser allows execution
     26 on a page where it should be blocked, or blocks execution on a page where it
     27 should be allowed.
     28 
     29 '''
     30 
     31 args_dict = utils.args_to_dict(args)
     32 
     33 job.run_test('policy_JavaScriptBlockedForUrls', **args_dict)
     34