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 = "dhaddock, Chromium OS" 6NAME = "autoupdate_P2P.delta" 7PURPOSE = "Test autoupdate via peer to peer(P2P)." 8TIME = "MEDIUM" 9TEST_CATEGORY = "Functional" 10TEST_CLASS = "platform" 11TEST_TYPE = "server" 12ATTRIBUTES = "suite:au-perbuild" 13SYNC_COUNT = 2 14JOB_RETRIES = 2 15DOC = """ 16This tests autoupdate between two devices via peer to peer. 17 18Since the test uses two different DUTs in the lab together it is more 19difficult to debug at your desk. 20 21Use the control.local to run this test locally. 22 23""" 24 25from autotest_lib.server import utils as server_utils 26 27def run(ntuple): 28 host_list = [] 29 for machine in ntuple: 30 host_list.append(hosts.create_host(machine)) 31 job.run_test('autoupdate_P2P', hosts=host_list) 32 33ntuples, failures = server_utils.form_ntuples_from_machines(machines, 34 SYNC_COUNT) 35 36# Use log=False in parallel_simple to avoid an exception in setting up 37# the incremental parser when SYNC_COUNT > 1. 38job.parallel_simple(run, ntuples, log=False) 39