From 330fa5b148a2262419818626979fcb54d1e8b4d1 Mon Sep 17 00:00:00 2001 From: Sean McGinnis Date: Wed, 3 Oct 2018 15:06:05 -0500 Subject: [PATCH] Update unit test debug instructions Since we've moved to stestr, the test debugging instructions we had published in our documentation do not actually work anymore. This updates those instructions to show a couple possible methods that can be used to perform test debugging. Change-Id: I9946da0c0d9aa247ff820ee6c02e57bf86a2747d Signed-off-by: Sean McGinnis --- doc/source/contributor/testing.rst | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/doc/source/contributor/testing.rst b/doc/source/contributor/testing.rst index c900035e75f..adb12fe0437 100644 --- a/doc/source/contributor/testing.rst +++ b/doc/source/contributor/testing.rst @@ -233,9 +233,10 @@ Then run the unit test with pdb enabled: .. code-block:: bash source .tox/py35/bin/activate - testr init - ostestr --pdb cinder.tests.unit.test_volume_utils - # or - ostestr -n cinder.tests.unit.test_volume_utils - # or - ostestr -n cinder/tests/unit/test_context.py + + python -m testtools.run cinder.tests.unit.test_volume_utils + + # Or to get a list of tests to run + + python -m testtools.run discover -t ./ cinder/tests/unit --list | grep group > tests_to_run.txt + python -m testtools.run --load-list tests_to_run.txt