1# Copyright 2018 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 = 'harpreet' 6NAME = 'network_WiFi_ChaosConnectDisconnect.static_5Ghz' 7TIME = 'LONG' 8TEST_TYPE = 'server' 9ATTRIBUTES = 'suite:wifi_interop' 10DEPENDENCIES = 'chaos_dut' 11 12DOC = """ 13This script iterates through all 5Ghz access points in Chaos chamber. 14""" 15 16from autotest_lib.server.cros.ap_configurators import ap_spec 17from autotest_lib.server.cros.chaos_lib import static_runner 18 19def run_chaos_static(machine): 20 host = hosts.create_host(machine) 21 # Test all 5Ghz static APs on channel 36, 40, 44, 48, 149, 153, 157 and 161 22 ap_specs = [ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 23 channel = 36, 24 configurator_type=ap_spec.CONFIGURATOR_STATIC), 25 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 26 channel = 40, 27 configurator_type=ap_spec.CONFIGURATOR_STATIC), 28 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 29 channel = 44, 30 configurator_type=ap_spec.CONFIGURATOR_STATIC), 31 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 32 channel = 48, 33 configurator_type=ap_spec.CONFIGURATOR_STATIC), 34 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 35 channel = 149, 36 configurator_type=ap_spec.CONFIGURATOR_STATIC), 37 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 38 channel = 153, 39 configurator_type=ap_spec.CONFIGURATOR_STATIC), 40 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 41 channel = 157, 42 configurator_type=ap_spec.CONFIGURATOR_STATIC), 43 ap_spec.APSpec(band=ap_spec.BAND_5GHZ, 44 channel = 161, 45 configurator_type=ap_spec.CONFIGURATOR_STATIC)] 46 47 for spec in ap_specs: 48 runner = static_runner.StaticRunner( 49 'network_WiFi_ChaosConnectDisconnect', host, spec) 50 runner.run(job) 51 52parallel_simple(run_chaos_static, machines) 53