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

Side by Side Diff: build/android/pylib/gtest/test_package_apk.py

Issue 132463007: Enable presubmit pylint in build/android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address frankf review comments. Created 6 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
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 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 """Defines TestPackageApk to help run APK-based native tests.""" 5 """Defines TestPackageApk to help run APK-based native tests."""
6 6
7 import logging 7 import logging
8 import os 8 import os
9 import shlex 9 import shlex
10 import sys 10 import sys
11 import tempfile 11 import tempfile
12 import time 12 import time
13 13
14 from pylib import android_commands 14 from pylib import android_commands
15 from pylib import cmd_helper
16 from pylib import constants 15 from pylib import constants
17 from pylib import pexpect 16 from pylib import pexpect
18 from pylib.android_commands import errors 17 from pylib.android_commands import errors
19 18 from pylib.gtest.test_package import TestPackage
20 from test_package import TestPackage
21 19
22 20
23 class TestPackageApk(TestPackage): 21 class TestPackageApk(TestPackage):
24 """A helper class for running APK-based native tests.""" 22 """A helper class for running APK-based native tests."""
25 23
26 def __init__(self, suite_name): 24 def __init__(self, suite_name):
27 """ 25 """
28 Args: 26 Args:
29 suite_name: Name of the test suite (e.g. base_unittests). 27 suite_name: Name of the test suite (e.g. base_unittests).
30 """ 28 """
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 finally: 118 finally:
121 self.tool.CleanUpEnvironment() 119 self.tool.CleanUpEnvironment()
122 logfile = android_commands.NewLineNormalizer(sys.stdout) 120 logfile = android_commands.NewLineNormalizer(sys.stdout)
123 return self._WatchFifo(adb, timeout=10, logfile=logfile) 121 return self._WatchFifo(adb, timeout=10, logfile=logfile)
124 122
125 #override 123 #override
126 def Install(self, adb): 124 def Install(self, adb):
127 self.tool.CopyFiles() 125 self.tool.CopyFiles()
128 adb.ManagedInstall(self.suite_path, False, 126 adb.ManagedInstall(self.suite_path, False,
129 package_name=self._package_info.package) 127 package_name=self._package_info.package)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698