diff options
| author | Ross Burton <ross.burton@arm.com> | 2023-09-21 14:48:29 +0100 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2023-09-22 07:45:17 +0100 |
| commit | e5829e1e8b99d1df6ef00cebe804cb450e691881 (patch) | |
| tree | 831975c48319a44c3b58ac9b754ad7ee4dcae9a6 /meta/lib/oeqa/runtime | |
| parent | 1ef74b08ca5696401a7165143e5abaaec442d767 (diff) | |
| download | poky-e5829e1e8b99d1df6ef00cebe804cb450e691881.tar.gz | |
oeqa/runtime/parselogs: inline single-caller functions
There's no need to have one-liner functions to get the MACHINE or
WORKDIR when they're only called once.
(From OE-Core rev: 9478a665641f55cdc14f12a4409121ef95883d74)
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/runtime')
| -rw-r--r-- | meta/lib/oeqa/runtime/cases/parselogs.py | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/meta/lib/oeqa/runtime/cases/parselogs.py b/meta/lib/oeqa/runtime/cases/parselogs.py index e670df3ced..6e5dc75306 100644 --- a/meta/lib/oeqa/runtime/cases/parselogs.py +++ b/meta/lib/oeqa/runtime/cases/parselogs.py | |||
| @@ -223,12 +223,6 @@ class ParseLogsTest(OERuntimeTestCase): | |||
| 223 | cls.log_locations = log_locations | 223 | cls.log_locations = log_locations |
| 224 | cls.msg = '' | 224 | cls.msg = '' |
| 225 | 225 | ||
| 226 | def getMachine(self): | ||
| 227 | return self.td.get('MACHINE', '') | ||
| 228 | |||
| 229 | def getWorkdir(self): | ||
| 230 | return self.td.get('WORKDIR', '') | ||
| 231 | |||
| 232 | # Go through the log locations provided and if it's a folder | 226 | # Go through the log locations provided and if it's a folder |
| 233 | # create a list with all the .log files in it, if it's a file | 227 | # create a list with all the .log files in it, if it's a file |
| 234 | # just add it to that list. | 228 | # just add it to that list. |
| @@ -251,7 +245,7 @@ class ParseLogsTest(OERuntimeTestCase): | |||
| 251 | 245 | ||
| 252 | # Copy the log files to be parsed locally | 246 | # Copy the log files to be parsed locally |
| 253 | def transfer_logs(self, log_list): | 247 | def transfer_logs(self, log_list): |
| 254 | workdir = self.getWorkdir() | 248 | workdir = self.td.get('WORKDIR') |
| 255 | self.target_logs = workdir + '/' + 'target_logs' | 249 | self.target_logs = workdir + '/' + 'target_logs' |
| 256 | target_logs = self.target_logs | 250 | target_logs = self.target_logs |
| 257 | if os.path.exists(target_logs): | 251 | if os.path.exists(target_logs): |
| @@ -278,7 +272,7 @@ class ParseLogsTest(OERuntimeTestCase): | |||
| 278 | grepcmd += '" ' + str(log) + " | grep -Eiv \'" | 272 | grepcmd += '" ' + str(log) + " | grep -Eiv \'" |
| 279 | 273 | ||
| 280 | try: | 274 | try: |
| 281 | errorlist = ignore_errors[self.getMachine()] | 275 | errorlist = ignore_errors[self.td.get('MACHINE')] |
| 282 | except KeyError: | 276 | except KeyError: |
| 283 | self.msg += 'No ignore list found for this machine, using default\n' | 277 | self.msg += 'No ignore list found for this machine, using default\n' |
| 284 | errorlist = ignore_errors['default'] | 278 | errorlist = ignore_errors['default'] |
