Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Side by Side Diff: slave/skia_slave_scripts/run_decoding_tests.py

Issue 16226005: Run skimage on the bots. (Closed) Base URL: https://skia.googlecode.com/svn/buildbot
Patch Set: Remove change to install.py Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 #!/usr/bin/env python
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 """ Run the Skia skimage executable. """
7
8 from build_step import BuildStep
9 from utils.gs_utils import TIMESTAMP_COMPLETED_FILENAME
10 import os
11 import sys
12
13 class RunDecodingTests(BuildStep):
14 def _Run(self):
15 image_dir = self._device_dirs.SKImageInDir()
16
17 # Skip the time stamp file.
18 images = [os.path.join(image_dir, filename)
19 for filename in os.listdir(image_dir)
20 if not filename == TIMESTAMP_COMPLETED_FILENAME]
21 cmd = ['-r']
22 cmd.extend(images)
23
24 expectations_name = self._gm_image_subdir + '.json'
borenet 2013/06/26 17:37:54 I think the better way is to check whether self._g
scroggo 2013/06/26 18:30:15 Done.
25
26 # Read expectations, which were downloaded/copied to the device.
27 expectations_file = os.path.join(self._device_dirs.SKImageExpectedDir(),
28 expectations_name)
29
30 if os.path.exists(expectations_file):
borenet 2013/06/26 17:37:54 This won't work for Android or ChromeOS.
scroggo 2013/06/26 18:30:15 Added DevicePathExists. I also switched from os.p
31 cmd.extend(['--readExpectationsPath', expectations_file])
32
33 # Write the expectations file, in case any did not match.
34 output_expectations_file = os.path.join(self._device_dirs.SKImageOutDir(),
35 expectations_name)
36 cmd.extend(['--createExpectationsPath', output_expectations_file])
37
38 # Draw any mismatches to the same folder as the output json.
39 cmd.extend(['--mismatchPath', self._device_dirs.SKImageOutDir()])
40
41 self.RunFlavoredCmd('skimage', cmd)
42
43
44 if '__main__' == __name__:
45 sys.exit(BuildStep.RunBuildStep(RunDecodingTests))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698