test-user-mode: handle exit status for signals. Fix #61.

This commit is contained in:
Ciro Santilli 六四事件 法轮功
2019-05-08 00:00:04 +00:00
parent 7a007c66fe
commit 887dd8a31f
3 changed files with 16 additions and 6 deletions

View File

@@ -59,12 +59,15 @@ If given, run only the given tests. Otherwise, run all tests.
'userland': os.path.relpath(os.path.join(path_abs, in_filename), os.getcwd()),
})
cur_run_args.update(my_path_properties['test_run_args'])
error = thread_pool.submit({
run_test_args = {
'expected_exit_status': my_path_properties['exit_status'],
'run_args': cur_run_args,
'run_obj': self.import_path_main('run'),
'test_id': path_relative_root,
})
}
if my_path_properties['receives_signal']:
run_test_args['expected_exit_status'] = 128 - my_path_properties['exit_status']
error = thread_pool.submit(run_test_args)
if error is not None:
if self.env['quit_on_fail']:
raise common.ExitLoop()