How can I see print() statements in behave (BDD)

前端 未结 5 915
野趣味
野趣味 2020-12-08 06:38

Context: I am using Python with Behave (BDD).

Whether I run my tests from the command line (behave) or from a custom main(), the behavior is the same: the test runs

5条回答
  •  無奈伤痛
    2020-12-08 07:13

    behave.ini doesn't work for me.
    I choose to

    • use the --no-capture argument to see print() statements in the console (though the last print() never going to appear, and I don't know why), or
    • redirect the output to a file so I can see all the stdout lines there to debug.

提交回复
热议问题