aboutsummaryrefslogtreecommitdiff
path: root/buildbot_test_toolchains.py
diff options
context:
space:
mode:
authorCaroline Tice <cmtice@google.com>2016-04-14 09:19:02 -0700
committerchrome-bot <chrome-bot@chromium.org>2016-04-14 19:01:50 +0000
commiteddb06396dc17fcec418c3aadc234f737b63c876 (patch)
tree73cc836f4d6faf44b3a682fc5dec45599605d0ee /buildbot_test_toolchains.py
parenteabfd367c30c20ecdf0adb1f0281fc02dca10102 (diff)
downloadtoolchain-utils-eddb06396dc17fcec418c3aadc234f737b63c876.tar.gz
[crosperf] Fix more lint errors.
BUG=chromium:567921 Test=Tested in my directory. Change-Id: Ibe128dd030887e0372380fb8f95a5e37ee63feeb Reviewed-on: https://chrome-internal-review.googlesource.com/255303 Commit-Ready: Caroline Tice <cmtice@google.com> Tested-by: Caroline Tice <cmtice@google.com> Reviewed-by: Yunlian Jiang <yunlian@google.com>
Diffstat (limited to 'buildbot_test_toolchains.py')
-rwxr-xr-xbuildbot_test_toolchains.py56
1 files changed, 28 insertions, 28 deletions
diff --git a/buildbot_test_toolchains.py b/buildbot_test_toolchains.py
index 58e76b45..4cad4c7a 100755
--- a/buildbot_test_toolchains.py
+++ b/buildbot_test_toolchains.py
@@ -12,8 +12,8 @@ well as copying the images into the seven-day reports directory.
from __future__ import print_function
+import argparse
import datetime
-import optparse
import os
import re
import sys
@@ -329,33 +329,33 @@ def Main(argv):
# Common initializations
command_executer.InitCommandExecuter()
- parser = optparse.OptionParser()
- parser.add_option('--remote',
- dest='remote',
- help='Remote machines to run tests on.')
- parser.add_option('--board',
- dest='board',
- default='x86-zgb',
- help='The target board.')
- parser.add_option('--chromeos_root',
- dest='chromeos_root',
- help='The chromeos root from which to run tests.')
- parser.add_option('--weekday',
- default='',
- dest='weekday',
- help='The day of the week for which to run tests.')
- parser.add_option('--patch',
- dest='patches',
- help='The patches to use for the testing, '
- "seprate the patch numbers with ',' "
- 'for more than one patches.')
- parser.add_option('--noschedv2',
- dest='noschedv2',
- action='store_true',
- default=False,
- help='Pass --noschedv2 to crosperf.')
-
- options, _ = parser.parse_args(argv)
+ parser = argparse.ArgumentParser()
+ parser.add_argument('--remote',
+ dest='remote',
+ help='Remote machines to run tests on.')
+ parser.add_argument('--board',
+ dest='board',
+ default='x86-zgb',
+ help='The target board.')
+ parser.add_argument('--chromeos_root',
+ dest='chromeos_root',
+ help='The chromeos root from which to run tests.')
+ parser.add_argument('--weekday',
+ default='',
+ dest='weekday',
+ help='The day of the week for which to run tests.')
+ parser.add_argument('--patch',
+ dest='patches',
+ help='The patches to use for the testing, '
+ "seprate the patch numbers with ',' "
+ 'for more than one patches.')
+ parser.add_argument('--noschedv2',
+ dest='noschedv2',
+ action='store_true',
+ default=False,
+ help='Pass --noschedv2 to crosperf.')
+
+ options = parser.parse_args(argv[1:])
if not options.board:
print('Please give a board.')
return 1