[openstack-dev] How to debug test using pdb

Ben Nemec openstack at nemebean.com
Mon Dec 1 18:19:17 UTC 2014


I don't personally use the debugger much, but there is a helper script
that is supposed to allow debugging:
https://github.com/openstack/oslotest/blob/master/tools/oslo_debug_helper

On 11/30/2014 05:08 AM, Saju M wrote:
> Hi,
> 
> How to debug test using pdb
> 
> I want to debug tests and tried following methods, but didn't work
> (could not see pdb> console).
> I could see only the message "Tests running..." and command got stuck.
> 
> I tried this with python-neutronclient, that does not have run_test.sh
> 
> Method-1:
> #source .tox/py27/bin/activate
> #.tox/py27/bin/python -m testtools.run
> neutronclient.tests.unit.test_cli20_network.CLITestV20NetworkJSON.test_create_network
> 
> Method-2:
> #testr list-tests '(CLITestV20NetworkJSON.test_create_network)' > my-list
> #python -m testtools.run discover --load-list my-list
> 
> 
> 
> 
> 
> _______________________________________________
> OpenStack-dev mailing list
> OpenStack-dev at lists.openstack.org
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
> 




More information about the OpenStack-dev mailing list