summaryrefslogtreecommitdiff
path: root/doc/rtd/topics
diff options
context:
space:
mode:
authorChad Smith <chad.smith@canonical.com>2018-06-12 10:14:07 -0600
committerChad Smith <chad.smith@canonical.com>2018-06-12 10:14:07 -0600
commit7b3c21615dac3b0d9163c9883309a2e7b675622a (patch)
treec9a29bea0a1677d651861eaa9a93e6f44a60598c /doc/rtd/topics
parentc3f1ad9abd4a28c1b4c1f34db28ac72a646cdca6 (diff)
downloadvyos-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 'doc/rtd/topics')
-rw-r--r--doc/rtd/topics/tests.rst7
1 files changed, 6 insertions, 1 deletions
diff --git a/doc/rtd/topics/tests.rst b/doc/rtd/topics/tests.rst
index cac4a6e4..b83bd899 100644
--- a/doc/rtd/topics/tests.rst
+++ b/doc/rtd/topics/tests.rst
@@ -58,7 +58,8 @@ explaining how to run one or the other independently.
$ tox -e citest -- run --verbose \
--os-name stretch --os-name xenial \
--deb cloud-init_0.7.8~my_patch_all.deb \
- --preserve-data --data-dir ~/collection
+ --preserve-data --data-dir ~/collection \
+ --preserve-instance
The above command will do the following:
@@ -76,6 +77,10 @@ The above command will do the following:
* ``--preserve-data`` always preserve collected data, do not remove data
after successful test run
+* ``--preserve-instance`` do not destroy the instance after test to allow
+ for debugging the stopped instance during integration test development. By
+ default, test instances are destroyed after the test completes.
+
* ``--data-dir ~/collection`` write collected data into `~/collection`,
rather than using a temporary directory