scripts: twister: Remove unused statuses
TestInstanceStatus of TIMEOUT and FLASH were never really used. They were checked for, but never assigned. Signed-off-by: Lukasz Mrugala <lukaszx.mrugala@intel.com>
This commit is contained in:
parent
5c6c44a247
commit
6f452e81f7
3 changed files with 4 additions and 15 deletions
|
|
@ -1019,7 +1019,7 @@ class ProjectBuilder(FilterBuilder):
|
|||
else:
|
||||
more_info = "build"
|
||||
|
||||
if ( instance.status in [TestInstanceStatus.ERROR, TestInstanceStatus.FAIL, TestInstanceStatus.TIMEOUT, TestInstanceStatus.FLASH]
|
||||
if ( instance.status in [TestInstanceStatus.ERROR, TestInstanceStatus.FAIL]
|
||||
and hasattr(self.instance.handler, 'seed')
|
||||
and self.instance.handler.seed is not None ):
|
||||
more_info += "/seed: " + str(self.options.seed)
|
||||
|
|
@ -1027,7 +1027,7 @@ class ProjectBuilder(FilterBuilder):
|
|||
results.done, total_tests_width, total_to_do , instance.platform.name,
|
||||
instance.testsuite.name, status, more_info))
|
||||
|
||||
if instance.status in [TestInstanceStatus.ERROR, TestInstanceStatus.FAIL, TestInstanceStatus.TIMEOUT]:
|
||||
if instance.status in [TestInstanceStatus.ERROR, TestInstanceStatus.FAIL]:
|
||||
self.log_info_file(self.options.inline_logs)
|
||||
else:
|
||||
completed_perc = 0
|
||||
|
|
|
|||
|
|
@ -17,10 +17,8 @@ class TestInstanceStatus(str, Enum):
|
|||
ERROR = 'error'
|
||||
FAIL = 'failed'
|
||||
FILTER = 'filtered'
|
||||
FLASH = 'flash_error'
|
||||
PASS = 'passed'
|
||||
SKIP = 'skipped'
|
||||
TIMEOUT = 'timeout'
|
||||
|
||||
|
||||
# Possible direct assignments:
|
||||
|
|
|
|||
|
|
@ -1976,23 +1976,14 @@ TESTDATA_13 = [
|
|||
['Unknown status = unknown status'],
|
||||
'INFO - Total complete: 20/ 25 80% skipped: 3,' \
|
||||
' failed: 2, error: 1\r'
|
||||
),
|
||||
(
|
||||
TestInstanceStatus.TIMEOUT, True, False, True,
|
||||
['INFO 20/25 dummy platform' \
|
||||
' dummy.testsuite.name' \
|
||||
' UNKNOWN' \
|
||||
' (dummy handler type: dummy dut, 60.000s/seed: 123)'],
|
||||
None
|
||||
),
|
||||
)
|
||||
]
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
'status, verbose, cmake_only, ready_run, expected_logs, expected_out',
|
||||
TESTDATA_13,
|
||||
ids=['verbose error cmake only', 'failed', 'verbose skipped', 'filtered',
|
||||
'verbose passed ready run', 'verbose passed', 'unknown status',
|
||||
'timeout']
|
||||
'verbose passed ready run', 'verbose passed', 'unknown status']
|
||||
)
|
||||
def test_projectbuilder_report_out(
|
||||
capfd,
|
||||
|
|
|
|||
Loading…
Reference in a new issue