diff options
Diffstat (limited to 'tests/run_tests.py')
| -rwxr-xr-x | tests/run_tests.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/tests/run_tests.py b/tests/run_tests.py index 6f4b399..fa75539 100755 --- a/tests/run_tests.py +++ b/tests/run_tests.py @@ -32,6 +32,12 @@ args.add_argument('--unittests', '-u', action='store_true', help='Run unittests. args.add_argument('--doctests', '-d', action='store_true', help='Run doctests.') args.add_argument('--integration', '-i', action='store_true', help='Run integration tests.') args.add_argument( + '--all', + '-a', + action='store_true', + help='Run unittests, doctests and integration tests. Equivalient to -u -d -i', +) +args.add_argument( '--coverage', '-c', action='store_true', help='Run tests and capture code coverage data' ) @@ -347,13 +353,13 @@ def main() -> Optional[int]: logger.debug('Clearing existing coverage data via "coverage erase".') exec_utils.cmd('coverage erase') - if config.config['unittests']: + if config.config['unittests'] or config.config['all']: saw_flag = True threads.append(UnittestTestRunner(params)) - if config.config['doctests']: + if config.config['doctests'] or config.config['all']: saw_flag = True threads.append(DoctestTestRunner(params)) - if config.config['integration']: + if config.config['integration'] or config.config['all']: saw_flag = True threads.append(IntegrationTestRunner(params)) @@ -412,7 +418,7 @@ def main() -> Optional[int]: ) time.sleep(0.5) - print('[2K\rFinal Report:') + print(f'{ansi.clear_line()}Final Report:') if config.config['coverage']: code_coverage_report() total_problems = test_results_report(results) |
