summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-02-25 14:02:17 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-02-26 11:59:52 +0000
commit401d022a26ab66076f0e90bd678e1e810aef36fb (patch)
tree77d1c0ff6ff1e0ed357aac49147be152acff8825 /scripts
parentffaee6bd482d2bbf32e78306e3884985e3078184 (diff)
downloadpoky-401d022a26ab66076f0e90bd678e1e810aef36fb.tar.gz
resulttool/regression: Ensure LTP results are only compared against other LTP runs
If a test result contains LTP test results, it should only be compared with other runs containing LTP test results. (From OE-Core rev: 4dbbf2f4a85620a08dc2fa65095dc17fe6c530f8) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/resulttool/regression.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/scripts/lib/resulttool/regression.py b/scripts/lib/resulttool/regression.py
index 1b0c8335a3..04a2f3fbb0 100644
--- a/scripts/lib/resulttool/regression.py
+++ b/scripts/lib/resulttool/regression.py
@@ -146,6 +146,7 @@ def can_be_compared(logger, base, target):
146 run with different tests sets or parameters. Return true if tests can be 146 run with different tests sets or parameters. Return true if tests can be
147 compared 147 compared
148 """ 148 """
149 ret = True
149 base_configuration = base['configuration'] 150 base_configuration = base['configuration']
150 target_configuration = target['configuration'] 151 target_configuration = target['configuration']
151 152
@@ -165,7 +166,11 @@ def can_be_compared(logger, base, target):
165 logger.debug(f"Enriching {target_configuration['STARTTIME']} with {guess}") 166 logger.debug(f"Enriching {target_configuration['STARTTIME']} with {guess}")
166 target_configuration['OESELFTEST_METADATA'] = guess 167 target_configuration['OESELFTEST_METADATA'] = guess
167 168
168 return metadata_matches(base_configuration, target_configuration) \ 169 # Test runs with LTP results in should only be compared with other runs with LTP tests in them
170 if base_configuration.get('TEST_TYPE') == 'runtime' and any(result.startswith("ltpresult") for result in base['result']):
171 ret = target_configuration.get('TEST_TYPE') == 'runtime' and any(result.startswith("ltpresult") for result in target['result'])
172
173 return ret and metadata_matches(base_configuration, target_configuration) \
169 and machine_matches(base_configuration, target_configuration) 174 and machine_matches(base_configuration, target_configuration)
170 175
171 176