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 ATTRIBUTES = "suite:regression"
      8 SUITE = "regression"
      9 TIME = "SHORT"
     10 TEST_CATEGORY = "General"
     11 TEST_CLASS = "enterprise"
     12 TEST_TYPE = "client"
     13 
     14 DOC = """
     15 Verify effects of JavaScriptBlockedForUrls policy on client behavior.
     16 
     17 This test verifies the effect of the JavaScriptBlockedForUrls user policy on
     18 Chrome OS client behavior when user policy DefaultJavaScriptSetting=1, meaning
     19 allow JavaScript on all pages except for those in JavaScriptBlockedForUrls.
     20 It exercises a range of policy values using four unique named test cases:
     21 NotSet_AllowJS, SingleUrl_BlockJS, MultipleUrls_AllowJS, and
     22 MultipleUrls_BlockJS. See the test file for a full description of what each
     23 test case does.
     24 
     25 In general, a test shall pass if the browser blocks JavaScript execution only
     26 on a test page with a URL that matches one or more of the URL patterns listed
     27 in JavaScriptBlockedForUrls. A test shall fail if the browser allows execution
     28 on a page where it should be blocked, or blocks execution on a page where it
     29 should be allowed.
     30 
     31 Usage example:
     32 $ test_that <IPAddress> JavaScriptBlockedForUrls --args="mode=single
     33 case=SingleUrl_BlockJS env=cr-dev username=test (a] crosqa4.com password=test0000"
     34 
     35 Runs a single test case (e.g., SingleUrl_BlockJS) against a device with the
     36 specified IP address, using the Staging environment on the cros-dev DM Server,
     37 and signing in to the device with the given username and password.
     38 
     39 """
     40 
     41 job.run_test("policy_JavaScriptBlockedForUrls", args=args)
     42