Reputation: 2283
I'm trying to debug a test using nosetests in PyCharm. I need to stop at a breakpoint and do some interactive debugging using the PyCharm debug console. However, whenever I type anything at the debug console prompt, nothing is printed; I just get a new prompt. The debug console works perfectly with pytest, but I need to use nosetests for this particular test. How can I get the console to work correctly?
Upvotes: 16
Views: 3232
Reputation: 18767
Under the Tools
menu, select Edit Configurations
. In the dialog, expand Python tests
and select the nosetests you are running. On the Configuration
tab, under the Nosetests
section, make sure the checkbox in front of Params
is checked and then add -s
as a parameter to it. Apply
and Save
.
Upvotes: 2
Reputation: 111
Under the "Tools" menu, select "Edit Configurations." In the dialog, expand "Python tests" and select the nosetests you are running. Add "-s" as an "Additional Argument".
Upvotes: 11
Reputation: 6567
Most likely your nose runner suppressing stdout. Try running nosetests with -s
Upvotes: 20