How can I automatically run py.test when the relative command has been changed?

Via autonose or nosy, it will automatically run nosetests after some test files or relative files are modified. I would like to ask if py.test gives a similar function, are there any other tools that can automatically trigger py.test.

+4
source share
1 answer

You can install the pytest-xdist plugin and issue:

$ py.test --looponfail <filename> 

You can also set the ini-file option "looponfailroots" to direct the plugin where to look for changes.

+4
source

Source: https://habr.com/ru/post/1433283/


All Articles