Output from print() showing after the end of the test, not while tests are running

I am running tests with:

from unittest import TestCase

Everything works well, but I only see the output of the prints from the tests at the end.

I would like to see the output of each print in real time because some tests are slow and I would know if it's hanging because something went wrong or it's just slowly doing its job.

0
1 comment

I found an ugly workaround: put a breakpoint on the first print, click on the console, press enter, press F9.

Pressing enter on the console writes "PyDev console: starting.", which I'm guessing means that the console is starting!

After the console startup has been manually triggered and the test execution is resumed by pressing F9, the output shows in the console in real time, as expected.

Is there a way to start the console automatically?

0

Please sign in to leave a comment.