1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-09-01 19:02:31 +01:00

Updated pylint for v1.5.1

Fixed WA for the latest version of pylint (1.5.1)
This commit is contained in:
Sebastian Goscik
2015-12-09 15:43:35 +00:00
parent 344bc519c4
commit bef8fb40ef
35 changed files with 86 additions and 102 deletions

View File

@@ -164,7 +164,7 @@ class AndroidDevice(BaseLinuxDevice): # pylint: disable=W0223
raise DeviceError('Could not boot {} ({}).'.format(self.name, self.adb_name))
while iteration_number < max_iterations:
available = (1 == int('0' + adb_shell(self.adb_name, 'getprop sys.boot_completed', timeout=self.default_timeout)))
available = (int('0' + (adb_shell(self.adb_name, 'getprop sys.boot_completed', timeout=self.default_timeout))) == 1)
if available:
break
else:
@@ -331,10 +331,7 @@ class AndroidDevice(BaseLinuxDevice): # pylint: disable=W0223
self._check_ready()
output = adb_shell(self.adb_name, 'if [ -e \'{}\' ]; then echo 1; else echo 0; fi'.format(filepath),
timeout=self.default_timeout)
if int(output):
return True
else:
return False
return bool(int(output))
def install(self, filepath, timeout=default_timeout, with_name=None): # pylint: disable=W0221
ext = os.path.splitext(filepath)[1].lower()
@@ -739,4 +736,3 @@ class BigLittleDevice(AndroidDevice): # pylint: disable=W0223
parameters = [
Parameter('scheduler', default='hmp', override=True),
]

View File

@@ -248,7 +248,7 @@ class BaseLinuxDevice(Device): # pylint: disable=abstract-method
self.execute('echo {} > \'{}\''.format(value, sysfile), check_exit_code=False, as_root=True)
if verify:
output = self.get_sysfile_value(sysfile)
if not output.strip() == value: # pylint: disable=E1103
if output.strip() != value: # pylint: disable=E1103
message = 'Could not set the value of {} to {}'.format(sysfile, value)
raise DeviceError(message)
self._written_sysfiles.append(sysfile)
@@ -476,7 +476,7 @@ class BaseLinuxDevice(Device): # pylint: disable=abstract-method
if isinstance(on_cpus, basestring):
on_cpus = ranges_to_list(on_cpus)
if isiterable(on_cpus):
on_cpus = list_to_mask(on_cpus)
on_cpus = list_to_mask(on_cpus) # pylint: disable=redefined-variable-type
command = '{} taskset 0x{:x} {}'.format(self.busybox, on_cpus, command)
if in_directory:
command = 'cd {} && {}'.format(in_directory, command)
@@ -807,4 +807,3 @@ class LinuxDevice(BaseLinuxDevice):
def ensure_screen_is_on(self):
pass # TODO