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

Side by Side Diff: tools/skp/recreate_skps.py

Issue 737123005: webpages_playback.py: Support storing to local directories (Closed) Base URL: https://skia.googlesource.com/skia.git@webpages-replay-docs
Patch Set: rebase Created 5 years, 8 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 | « no previous file | tools/skp/webpages_playback.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2014 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2014 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 6
7 """Run the webpages_playback automation script.""" 7 """Run the webpages_playback automation script."""
8 8
9 9
10 import os 10 import os
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 # is already up. 50 # is already up.
51 pass 51 pass
52 52
53 upload_dir = 'playback_%d' % skp_version 53 upload_dir = 'playback_%d' % skp_version
54 webpages_playback_cmd = [ 54 webpages_playback_cmd = [
55 'python', os.path.join(os.path.dirname(os.path.realpath(__file__)), 55 'python', os.path.join(os.path.dirname(os.path.realpath(__file__)),
56 'webpages_playback.py'), 56 'webpages_playback.py'),
57 '--page_sets', 'all', 57 '--page_sets', 'all',
58 '--browser_executable', browser_executable, 58 '--browser_executable', browser_executable,
59 '--non-interactive', 59 '--non-interactive',
60 '--upload_to_gs', 60 '--upload',
61 '--alternate_upload_dir', upload_dir, 61 '--alternate_upload_dir', upload_dir,
62 '--chrome_src_path', chrome_src_path, 62 '--chrome_src_path', chrome_src_path,
63 ] 63 ]
64 64
65 try: 65 try:
66 shell_utils.run(webpages_playback_cmd) 66 shell_utils.run(webpages_playback_cmd)
67 finally: 67 finally:
68 # Clean up any leftover browser instances. This can happen if there are 68 # Clean up any leftover browser instances. This can happen if there are
69 # telemetry crashes, processes are not always cleaned up appropriately by 69 # telemetry crashes, processes are not always cleaned up appropriately by
70 # the webpagereplay and telemetry frameworks. 70 # the webpagereplay and telemetry frameworks.
(...skipping 12 matching lines...) Expand all
83 print 'writing %s: %s' % (SKP_VERSION_FILE, skp_version) 83 print 'writing %s: %s' % (SKP_VERSION_FILE, skp_version)
84 with open(SKP_VERSION_FILE, 'w') as f: 84 with open(SKP_VERSION_FILE, 'w') as f:
85 f.write(str(skp_version)) 85 f.write(str(skp_version))
86 86
87 87
88 if '__main__' == __name__: 88 if '__main__' == __name__:
89 if len(sys.argv) != 3: 89 if len(sys.argv) != 3:
90 print >> sys.stderr, 'USAGE: %s <chrome src path> <browser executable>' 90 print >> sys.stderr, 'USAGE: %s <chrome src path> <browser executable>'
91 sys.exit(1) 91 sys.exit(1)
92 main(*sys.argv[1:]) 92 main(*sys.argv[1:])
OLDNEW
« no previous file with comments | « no previous file | tools/skp/webpages_playback.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698