• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2016 The Chromium 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"""A test which verifies the function of hardware JPEG decode accelerator."""
6
7import logging
8from autotest_lib.client.cros import chrome_binary_test
9
10class video_JpegDecodeAccelerator(chrome_binary_test.ChromeBinaryTest):
11    """
12    This test is a wrapper of the chrome unittest binary:
13    jpeg_decode_accelerator_unittest.
14
15    The jpeg_decode_accelerator_unittest uses the built-in default JPEG image:
16    peach_pi-1280x720.jpg during test.  The image is bundled as part of the
17    chromeos-chrome package if USE=build_test is set.  ChromeBinaryTest will
18    automatically locate the image for us when the test is run.
19    """
20
21    version = 1
22    binary = 'jpeg_decode_accelerator_unittest'
23
24
25    @chrome_binary_test.nuke_chrome
26    def run_once(self):
27        """
28        Runs jpeg_decode_accelerator_unittest on the device.
29
30        @raises: error.TestFail for jpeg_decode_accelerator_unittest failures.
31        """
32        logging.debug('Starting video_JpegDecodeAccelerator')
33        self.run_chrome_test_binary(self.binary)
34