diff options
author | Luis Lozano <llozano@google.com> | 2020-02-07 10:54:08 -0800 |
---|---|---|
committer | Luis Lozano <llozano@chromium.org> | 2020-02-07 19:17:46 +0000 |
commit | be756e05b7e75efa9fbd31cc1c3debdf915301ec (patch) | |
tree | db18c0bf5c0546ff591806d2d20ca3e5f7f73844 | |
parent | d820cda773d5c8765bb9c44881d4516191463379 (diff) | |
download | toolchain-utils-be756e05b7e75efa9fbd31cc1c3debdf915301ec.tar.gz |
toolchain-utils: move weekday testing into nightly-testing dir.
BUG=None
TEST=None.
Change-Id: I99b9c1c09bcf7d6aaddd79f38e9ea8105f192eb0
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/toolchain-utils/+/2043954
Reviewed-by: George Burgess <gbiv@chromium.org>
Reviewed-by: Zhizhou Yang <zhizhouy@google.com>
Commit-Queue: Luis Lozano <llozano@chromium.org>
Tested-by: Luis Lozano <llozano@chromium.org>
Auto-Submit: Luis Lozano <llozano@chromium.org>
-rwxr-xr-x | auto_delete_nightly_test_data.py | 6 | ||||
-rwxr-xr-x | buildbot_test_toolchains.py | 3 | ||||
-rwxr-xr-x | weekly_report.py | 4 |
3 files changed, 9 insertions, 4 deletions
diff --git a/auto_delete_nightly_test_data.py b/auto_delete_nightly_test_data.py index 699e12a0..59280e1f 100755 --- a/auto_delete_nightly_test_data.py +++ b/auto_delete_nightly_test_data.py @@ -22,6 +22,8 @@ from cros_utils import constants from cros_utils import misc DIR_BY_WEEKDAY = ('Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun') +NIGHTLY_TESTS_WORKSPACE = os.path.join(constants.CROSTC_WORKSPACE, + 'nightly-tests') def CleanNumberedDir(s, dry_run=False): @@ -48,7 +50,7 @@ def CleanNumberedDir(s, dry_run=False): ## check 's' to make sure it is sane. A valid dir to be removed must be ## '/usr/local/google/crostc/(SUN|MON|TUE...|SAT)'. valid_dir_pattern = ( - '^' + constants.CROSTC_WORKSPACE + '/(' + '|'.join(DIR_BY_WEEKDAY) + ')') + '^' + NIGHTLY_TESTS_WORKSPACE + '/(' + '|'.join(DIR_BY_WEEKDAY) + ')') if not re.search(valid_dir_pattern, s): print('Trying to delete an invalid dir "{0}" (must match "{1}"), ' 'please check.'.format(s, valid_dir_pattern)) @@ -196,7 +198,7 @@ def Main(argv): dated_dir = DIR_BY_WEEKDAY[i - 1] rv += 0 if CleanDatedDir( - os.path.join(constants.CROSTC_WORKSPACE, dated_dir), + os.path.join(NIGHTLY_TESTS_WORKSPACE, dated_dir), options.dry_run) else 1 diff --git a/buildbot_test_toolchains.py b/buildbot_test_toolchains.py index 175dae5e..064f0db6 100755 --- a/buildbot_test_toolchains.py +++ b/buildbot_test_toolchains.py @@ -34,6 +34,7 @@ from cros_utils import buildbot_utils USE_LLVM_NEXT_PATCH = '513590' CROSTC_ROOT = '/usr/local/google/crostc' +NIGHTLY_TESTS_DIR = os.path.join(CROSTC_ROOT, 'nightly-tests') ROLE_ACCOUNT = 'mobiletc-prebuild' TOOLCHAIN_DIR = os.path.dirname(os.path.realpath(__file__)) MAIL_PROGRAM = '~/var/bin/mail-sheriff' @@ -145,7 +146,7 @@ class ToolchainComparator(object): Given the names of the trybot, vanilla and non-AFDO images, create the appropriate crosperf experiment file and launch crosperf on it. """ - experiment_file_dir = os.path.join(CROSTC_ROOT, self._weekday) + experiment_file_dir = os.path.join(NIGHTLY_TESTS_DIR, self._weekday) experiment_file_name = '%s_toolchain_experiment.txt' % self._board compiler_string = 'llvm' diff --git a/weekly_report.py b/weekly_report.py index 01db867d..476b9f0d 100755 --- a/weekly_report.py +++ b/weekly_report.py @@ -1,6 +1,8 @@ #!/usr/bin/env python2 +# -*- coding: utf-8 -*- # # Copyright Google Inc. 2014 + """Module to generate the 7-day crosperf reports.""" from __future__ import print_function @@ -205,7 +207,7 @@ def Main(argv): '%s.%s' % (timestamp, options.board), 'weekly_tests') for day in WEEKDAYS: - startdir = os.path.join(constants.CROSTC_WORKSPACE, day) + startdir = os.path.join(constants.CROSTC_WORKSPACE, 'nightly-tests', day) num_dirs = os.listdir(startdir) for d in num_dirs: exp_file = os.path.join(startdir, d, 'toolchain_experiment.txt') |