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

Side by Side Diff: content/test/gpu/page_sets/PRESUBMIT.py

Issue 1644723002: Update presubmit in gpu tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « content/test/gpu/gpu_tests/pixel.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import sys 5 import sys
6 6
7 7
8 def _GetChromiumSrcDir(input_api): 8 def _GetChromiumSrcDir(input_api):
9 return input_api.os_path.abspath(input_api.os_path.join( 9 return input_api.os_path.abspath(input_api.os_path.join(
10 input_api.PresubmitLocalPath(), '..', '..', '..', '..')) 10 input_api.PresubmitLocalPath(), '..', '..', '..', '..'))
11 11
12 12
13 def LoadSupport(input_api): 13 def LoadSupport(input_api):
14 if 'cloud_storage' not in globals(): 14 if 'cloud_storage' not in globals():
15 # Avoid leaking changes to global sys.path. 15 # Avoid leaking changes to global sys.path.
16 _old_sys_path = sys.path 16 _old_sys_path = sys.path
17 try: 17 try:
18 catapult_base_path = input_api.os_path.join( 18 catapult_base_path = input_api.os_path.join(
19 _GetChromiumSrcDir(input_api), 'third_party', 'catapult', 19 _GetChromiumSrcDir(input_api), 'third_party', 'catapult',
20 'catapult_base') 20 'catapult_base')
21 sys.path = [catapult_base_path] + sys.path 21 sys.path = [catapult_base_path] + sys.path
22 from catapult_base import cloud_storage # pylint: disable=import-error 22 from catapult_base import cloud_storage
23 globals()['cloud_storage'] = cloud_storage 23 globals()['cloud_storage'] = cloud_storage
24 finally: 24 finally:
25 sys.path = _old_sys_path 25 sys.path = _old_sys_path
26 26
27 return globals()['cloud_storage'] 27 return globals()['cloud_storage']
28 28
29 29
30 def _GetFilesNotInCloud(input_api): 30 def _GetFilesNotInCloud(input_api):
31 """Searches for .sha1 files and checks to see if they have already 31 """Searches for .sha1 files and checks to see if they have already
32 been uploaded Cloud Storage. Returns a list of those that have not. 32 been uploaded Cloud Storage. Returns a list of those that have not.
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 82
83 83
84 def CheckChangeOnUpload(input_api, output_api): 84 def CheckChangeOnUpload(input_api, output_api):
85 results = _VerifyFilesInCloud(input_api, output_api) 85 results = _VerifyFilesInCloud(input_api, output_api)
86 return results 86 return results
87 87
88 88
89 def CheckChangeOnCommit(input_api, output_api): 89 def CheckChangeOnCommit(input_api, output_api):
90 results = _VerifyFilesInCloud(input_api, output_api) 90 results = _VerifyFilesInCloud(input_api, output_api)
91 return results 91 return results
OLDNEW
« no previous file with comments | « content/test/gpu/gpu_tests/pixel.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698