blob: abbd7a25fd77ba5b5efa5578f6d436ac4a8409fe [file] [log] [blame]
# Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import logging
import os
from autotest_lib.server import autotest
from autotest_lib.server import hosts
from autotest_lib.server import test
class video_VDAStress(test.test):
VDA stress test run client video_VideoDecodeAccelerator tests on a list of
version = 1
def run_once(self, machine, server_videos_dir, videos):
host = hosts.create_host(machine)
host_at = autotest.Autotest(host)
for video in videos:
# Copy test vidoes from the server to the client.
file_name, sep, video_arg = video.partition(':')
file_path_at_server = os.path.join(server_videos_dir, file_name)
file_path_at_client = '/tmp/%s' % file_name
host.send_file(file_path_at_server, file_path_at_client)"Copied to the client: %s" % file_path_at_client)
# Run the client test with the downloaded video.
host_at.run_test('video_VideoDecodeAccelerator', videos=['%s%s%s' %
(file_path_at_client, sep, video_arg)],
gtest_filter='DecodeVariations*\/0')'rm %s' % file_path_at_client)