diff options
author | Chad Smith <chad.smith@canonical.com> | 2018-06-12 10:14:07 -0600 |
---|---|---|
committer | Chad Smith <chad.smith@canonical.com> | 2018-06-12 10:14:07 -0600 |
commit | 7b3c21615dac3b0d9163c9883309a2e7b675622a (patch) | |
tree | c9a29bea0a1677d651861eaa9a93e6f44a60598c /tests/cloud_tests/collect.py | |
parent | c3f1ad9abd4a28c1b4c1f34db28ac72a646cdca6 (diff) | |
download | vyos-cloud-init-7b3c21615dac3b0d9163c9883309a2e7b675622a.tar.gz vyos-cloud-init-7b3c21615dac3b0d9163c9883309a2e7b675622a.zip |
test: add optional --preserve-instance arg to integraiton tests
By default, integration tests destroy the test instances after each
test run. To aid debug and development of integration tests, support a
--preserve-instance argument which will leave the modified test instance
in a stopped state for further debug.
Diffstat (limited to 'tests/cloud_tests/collect.py')
-rw-r--r-- | tests/cloud_tests/collect.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/cloud_tests/collect.py b/tests/cloud_tests/collect.py index 78263bf5..75b50616 100644 --- a/tests/cloud_tests/collect.py +++ b/tests/cloud_tests/collect.py @@ -93,7 +93,8 @@ def collect_test_data(args, snapshot, os_name, test_name): # create test instance component = PlatformComponent( partial(platforms.get_instance, snapshot, user_data, - block=True, start=False, use_desc=test_name)) + block=True, start=False, use_desc=test_name), + preserve_instance=args.preserve_instance) LOG.info('collecting test data for test: %s', test_name) with component as instance: |