Pycharm configuration error for pytest

In my project I have a directory with my Python modules, and another ‘tests’ directory at the same level. I recently moved the modules out of a pointless ‘src’ directory! up to the top level of the project directory.

if I select a class in a Python file in my modules directory, and go through menus to ‘goto’ ‘test’, I am taken to the correct test class in the correct file in my ‘tests’ directory. If I pop up the menu on the green triangle to run the test, it fails saying it’s looking in the old directory structure. pytest finds the tests perfectly from the command line. I made a new run debug configuration, but the documentation is for people who already understand the system. There no explain of how or why pycharm does things.

so why doesn’t the ide know it’s misconfigured? I walked through it’s menu structure to find the test. I’ve invalidated caches and restarted. Documentation has no troubleshooting that I can find

1 comment




1.provide me with a whole error stack

2. a screenshot of the command you are running to launch the test in the command-line

3. logs folder zipped from Help | Collect logs and Diagnostic Data

4. screenshot of Run/Debug Configuration.



Please sign in to leave a comment.