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

Side by Side Diff: build/android/test_runner.py

Issue 2891403002: Workaround python time.strptime flake in Android tests (Closed)
Patch Set: revert test_runner.pydeps to where the master is Created 3 years, 7 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 | 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 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2013 The Chromium Authors. All rights reserved. 3 # Copyright 2013 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Runs all types of tests from one unified interface.""" 7 """Runs all types of tests from one unified interface."""
8 8
9 import argparse 9 import argparse
10 import collections 10 import collections
11 import contextlib 11 import contextlib
12 import itertools 12 import itertools
13 import logging 13 import logging
14 import os 14 import os
15 import shutil 15 import shutil
16 import signal 16 import signal
17 import sys 17 import sys
18 import threading 18 import threading
19 import traceback 19 import traceback
20 import unittest 20 import unittest
21 21
22 # Import _strptime before threaded code. datetime.datetime.strptime is
23 # threadsafe except for the initial import of the _strptime module.
24 # See http://crbug.com/724524 and https://bugs.python.org/issue7980.
25 import _strptime # pylint: disable=unused-import
26
22 from pylib.constants import host_paths 27 from pylib.constants import host_paths
23 28
24 if host_paths.DEVIL_PATH not in sys.path: 29 if host_paths.DEVIL_PATH not in sys.path:
25 sys.path.append(host_paths.DEVIL_PATH) 30 sys.path.append(host_paths.DEVIL_PATH)
26 31
27 from devil import base_error 32 from devil import base_error
28 from devil.utils import reraiser_thread 33 from devil.utils import reraiser_thread
29 from devil.utils import run_tests_helper 34 from devil.utils import run_tests_helper
30 35
31 from pylib import constants 36 from pylib import constants
(...skipping 893 matching lines...) Expand 10 before | Expand all | Expand 10 after
925 if e.is_infra_error: 930 if e.is_infra_error:
926 return constants.INFRA_EXIT_CODE 931 return constants.INFRA_EXIT_CODE
927 return constants.ERROR_EXIT_CODE 932 return constants.ERROR_EXIT_CODE
928 except: # pylint: disable=W0702 933 except: # pylint: disable=W0702
929 logging.exception('Unrecognized error occurred.') 934 logging.exception('Unrecognized error occurred.')
930 return constants.ERROR_EXIT_CODE 935 return constants.ERROR_EXIT_CODE
931 936
932 937
933 if __name__ == '__main__': 938 if __name__ == '__main__':
934 sys.exit(main()) 939 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698