PyCharm doesn't recognize pytests if their name doesn't start with Test


we're using pytest and we've re-configured it in `pytest.ini` to find classes that end their names in `Test` instead of beginning their names in `Test` for visual preference.

However, the PyCharm test runner gutter icons don't show for such classes nor methods under them. Is there any way to reconfigure the in-built test finder to support such configuration? (It would be best if it was able to autoconfigure itself from the `pytest.ini` file but any manual configuration even if it's something in internal registry would be fine)



I was wondering if someone had my same question, :D actually yes. I'm interested to know if there's an option for custom test names



this is a pytest specific rather than IDE. 


However, you are welcome to submit a feature request at

Information on how to use YouTrack:


Sorry to follow up but pytest allows to configure which test classes can be discovered, thus allowing it to discover *Test named classes.

Looks like Pycharm has hardcoded that it should look for Test* named classes instead of following whichever the configuration for pytest was provided.

I'm facing the same problem of not being able to run tests directly from the editor only on those classes.


Looks like the request for this feature was opened 4 years ago:


Please sign in to leave a comment.